Uploaded image for project: 'ClojureScript'
  1. CLJS-2408

js->clj does not work on objects with null prototype

    Details

    • Type: Bug
    • Status: Open
    • Priority: Major
    • Resolution: Unresolved
    • Affects versions: 1.9.908
    • Fix versions: None
    • Labels:
      None

      Description

      Version: 1.9.946
      Follow up from issue CLJS-1998 Closed

      cljs.user=> (js->clj #js {})
      {}
      
      cljs.user=> (js->clj (.create js/Object nil))
      #object[Object]
      
      cljs.user=> (keys (js->clj (.create js/Object nil)))
      org.mozilla.javascript.EcmaError: TypeError: Cannot find default value for object. (.cljs_rhino_repl/goog/../.cljs_rhino_repl/cljs/core.js#9915)
      	 (.cljs_rhino_repl/cljs/core.cljs:2930:10)
      	 cljs$core$seq (.cljs_rhino_repl/cljs/core.cljs:1212:13)
      	 cljs$core$keys (.cljs_rhino_repl/cljs/core.cljs:8648:3)
      	 (NO_SOURCE_FILE <cljs repl>:1:0)
      	 (NO_SOURCE_FILE <cljs repl>:1:0)
      

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              alex+import import
            • Votes:
              1 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated: