File tree Expand file tree Collapse file tree 2 files changed +11
-5
lines changed Expand file tree Collapse file tree 2 files changed +11
-5
lines changed Original file line number Diff line number Diff line change 334334(defmethod emit-constant Boolean [x] (if x " value_true" " value_false" ))
335335
336336(defmethod emit-constant java.util.regex.Pattern [x]
337- (emit-value-wrap :pattern-const nil (emits " pcre_pattern ( make_string (" (wrap-in-double-quotes (escape-string (str x))) " ))" ))
338- #_ (FIXME-IMPLEMENT (str " Cannot emit java.util.regex.Pattern for constant " x " yet." )))
337+
338+ (emit-value-wrap :pattern-const
339+ nil
340+ (emits " FUNCALL1 ((closure_t*)VAR_NAME (cljc_DOT_core_SLASH_re_pattern), make_string ("
341+ (wrap-in-double-quotes (escape-string (str x))) " ))" )))
339342
340343(defmethod emit-constant clojure.lang.Keyword [x]
341344 (emit-value-wrap :keyword nil
19871990(comment
19881991
19891992; ;the new way - use the REPL!!
1990- (require '[cljs .compiler :as comp])
1993+ (require '[cljc .compiler :as comp])
19911994(def repl-env (comp/repl-env ))
19921995(comp/repl repl-env)
19931996; having problems?, try verbose mode
Original file line number Diff line number Diff line change 9494 (recur (inc i) args))))
9595 a))
9696
97+ (defn ^boolean array? [cand]
98+ (has-type? cand Array))
99+
97100(defn make-array [size]
98101 (c* " make_array (integer_get (~{}))" size))
99102
@@ -891,7 +894,7 @@ reduces them without incurring seq initialization"
891894 (str ns " /" name)
892895 name)]
893896 #_(Symbol. ns name sym-str nil nil )
894- (c* " make_symbol( string_get_utf8( make_string_copy( string_get_utf8 ( ~{}) ) ) )" sym-str))))
897+ (c* " make_symbol( string_get_utf8( ~{}) )" sym-str))))
895898
896899
897900(defn ^boolean number? [n]
@@ -6315,7 +6318,7 @@ reduces them without incurring seq initialization"
63156318
63166319 (defn- parse-float [s]
63176320 (if-objc
6318- (§ s :floatValue )
6321+ (§ s :floatValue )
63196322 (c* " make_float (g_ascii_strtod (string_get_utf8 (~{}), NULL ) )" s)))
63206323
63216324
You can’t perform that action at this time.
0 commit comments