     (emit-constant (hash x))
     (emits ",")
     (emit-constant nil)
-    (emits ")")))
+    (emits "}")))
 
 ;; tagged literal support
 
 (defmethod emit-constant java.util.Date [^java.util.Date date]
-  (emits "new js.Date(" (.getTime date) ")"))
+  (emits "js.Date{" (.getTime date) "}"))
 
 (defmethod emit-constant java.util.UUID [^java.util.UUID uuid]
-  (emits "new cljs.core.UUID(\"" (.toString uuid) "\")"))
+  (emits "cljs.core.UUID{\"" (.toString uuid) "\"}"))
 
 (defmacro emit-wrap [env & body]
   `(let [env# ~env]

      (emit-constant (if ns
                       (str ns "/" name)
                       name))
      (emits ");\n"))))

(defn emit-constants-table-to-file [table dest]
  (with-open [out ^java.io.Writer (io/make-writer dest {})]

      (emits "cljs.core.PersistentVector.EMPTY")
      (let [cnt (count items)]
        (if (< cnt 32)
          (emits "cljs.core.PersistentVector{null, " cnt
            ", 5, cljs.core.PersistentVector.EMPTY_NODE, ["  (comma-sep items) "], null}")
          (emits "cljs.core.PersistentVector.fromArray([" (comma-sep items) "], true)"))))))

(defn distinct-constants? [items]
