Skip to content

Commit

Permalink
* upgrade to tools.reader 1.4.2
Browse files Browse the repository at this point in the history
  • Loading branch information
swannodette committed Apr 18, 2024
1 parent a53e163 commit f7166f0
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
2 changes: 1 addition & 1 deletion script/vendorize_deps
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ cd src/main/clojure/cljs

DJSON_RELEASE="2.4.0"
TRANSIT_RELEASE="1.0.329"
TREADER_RELEASE="1.3.7"
TREADER_RELEASE="1.4.2"

rm -rf data.json
git clone -b "v$DJSON_RELEASE" --depth 1 [email protected]:clojure/data.json.git
Expand Down
8 changes: 5 additions & 3 deletions src/main/clojure/cljs/vendor/clojure/tools/reader.clj
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@
java.util.regex.Pattern
(java.util List LinkedList)))

(set! *warn-on-reflection* true)

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; helpers
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
Expand Down Expand Up @@ -759,7 +761,7 @@
(ns-name *ns*)

(= \: (first token))
(some-> token (subs 1) parse-symbol second' symbol resolve-ns ns-name)
(some-> token (subs 1) parse-symbol second' symbol resolve-ns)

:else
(some-> token parse-symbol second'))]
Expand Down Expand Up @@ -1022,12 +1024,12 @@
([] (read+string (source-logging-push-back-reader *in*)))
([stream] (read+string stream true nil))
([^SourceLoggingPushbackReader stream eof-error? eof-value]
(let [^StringBuilder buf (doto (:buffer @(.source-log-frames stream)) (.setLength 0))
(let [^StringBuilder buf (doto ^StringBuilder (:buffer @(.source-log-frames stream)) (.setLength 0))
o (log-source stream (read stream eof-error? eof-value))
s (.trim (str buf))]
[o s]))
([opts ^SourceLoggingPushbackReader stream]
(let [^StringBuilder buf (doto (:buffer @(.source-log-frames stream)) (.setLength 0))
(let [^StringBuilder buf (doto ^StringBuilder (:buffer @(.source-log-frames stream)) (.setLength 0))
o (log-source stream (read opts stream))
s (.trim (str buf))]
[o s])))

0 comments on commit f7166f0

Please sign in to comment.