=> (cljs.reader/read-string "(re-matches #\".*ClojureScript \\d+\\.\\d+\\.\\d+ (.*)$\")")
Error: Unsupported escape character: \d.
at new cljs$core$ExceptionInfo (/js/cljs-runtime/cljs.core.js:37198:10)
at Function.eval [as cljs$core$IFn$_invoke$arity$3] (/js/cljs-runtime/cljs.core.js:37259:9)
at Function.eval [as cljs$core$IFn$_invoke$arity$2] (/js/cljs-runtime/cljs.core.js:37255:26)
at Function.eval [as cljs$core$IFn$_invoke$arity$variadic] (/js/cljs-runtime/cljs.tools.reader.impl.errors.js:52:25)
at Function.eval [as cljs$core$IFn$_invoke$arity$variadic] (/js/cljs-runtime/cljs.tools.reader.impl.errors.js:92:47)
at Object.cljs$tools$reader$impl$errors$throw_bad_escape_char [as throw_bad_escape_char] (/js/cljs-runtime/cljs.tools.reader.impl.errors.js:321:51)
at Object.cljs$tools$reader$edn$escape_char [as escape_char] (/js/cljs-runtime/cljs.tools.reader.edn.js:470:38)
at eval (/js/cljs-runtime/cljs.tools.reader.edn.js:485:39)
at cljs$tools$reader$edn$read_string_STAR_ (/js/cljs-runtime/cljs.tools.reader.edn.js:488:3)
But same input in clojure :
=> (read-string "(re-matches #\".*ClojureScript \\d+\\.\\d+\\.\\d+ (.*)$\")")
(re-matches #".*ClojureScript \d+\.\d+\.\d+ (.*)$")
Also :
(cljs.reader/read-string "(re-matches #\"hello\")")
doesn't read with cljs.reader/read-string while it reads with clojure read-string