From 3a63a2ff151e79c4d447feeff885c96b4c67494a Mon Sep 17 00:00:00 2001 From: Camilo Roca Date: Wed, 20 Nov 2019 23:31:30 +0100 Subject: [PATCH] fix: invalid keywords used --- src/clojure/parcera/antlr/java.clj | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/src/clojure/parcera/antlr/java.clj b/src/clojure/parcera/antlr/java.clj index b288fe8..85c225a 100644 --- a/src/clojure/parcera/antlr/java.clj +++ b/src/clojure/parcera/antlr/java.clj @@ -53,31 +53,31 @@ (cond ;; happens when the parser rule is a single lexer rule (identical? start stop) - {::start {:row (.getLine start) - :column (.getCharPositionInLine start)} - ::end {:row (.getLine start) - :column (Math/addExact (.getCharPositionInLine start) - (.length (.getText start)))}} + {:parcera.core/start {:row (.getLine start) + :column (.getCharPositionInLine start)} + :parcera.core/end {:row (.getLine start) + :column (Math/addExact (.getCharPositionInLine start) + (.length (.getText start)))}} ;; no end found - happens on errors (nil? stop) - {::start {:row (.getLine start) - :column (.getCharPositionInLine start)}} + {:parcera.core/start {:row (.getLine start) + :column (.getCharPositionInLine start)}} :else - {::start {:row (.getLine start) - :column (.getCharPositionInLine start)} - ::end {:row (.getLine stop) - :column (Math/addExact (.getCharPositionInLine stop) - (.length (.getText stop)))}})))) + {:parcera.core/start {:row (.getLine start) + :column (.getCharPositionInLine start)} + :parcera.core/end {:row (.getLine stop) + :column (Math/addExact (.getCharPositionInLine stop) + (.length (.getText stop)))}})))) (extend-type ErrorNodeImpl antlr/LocationInfo (span [^ErrorNodeImpl this] (let [token (.-symbol this)] - {::start {:row (.getLine token) - :column (.getCharPositionInLine token)}}))) + {:parcera.core/start {:row (.getLine token) + :column (.getCharPositionInLine token)}}))) (extend-type ClojureParser