                 debug.log "visitThisExpression"
                 @createLoad @findIdentifierInScope("%this"), "load_this"
 
+        visitSpreadElement: (n) ->
+                throw new Error("halp")
+                
         visitIdentifier: (n) ->
                 debug.log -> "identifier #{n.name}"
                 val = n.name

                else if is_intrinsic(lhs, "%getLocal")
                        ir.createStore rhvalue, @findIdentifierInScope lhs.arguments[0].name
                else if is_intrinsic(lhs, "%getGlobal")
                        pname = @getAtom lhs.arguments[0].name

                        @createCall @ejs_runtime.global_setprop, [pname, rhvalue], "globalpropstore_#{lhs.arguments[0].name}"
                else
                        throw new Error "unhandled lhs #{escodegen.generate lhs}"


        storeGlobal: (prop, value) ->
                # we store obj.prop, prop is an id
                if prop.type is Identifier
                        gname = prop.name
                else # prop.type is Literal
                        gname = prop.value

                if not hasOwn.call @ejs_globals, gname
                        throw new ReferenceError "unknown identifier `#{gname}' at line #{prop.loc.start.line}"

                c = @getAtom gname

                debug.log -> "createPropertyStore #{obj}[#{gname}]"
                        
                @createCall @ejs_runtime.global_setprop, [c, value], "globalpropstore_#{gname}"

        loadGlobal: (prop) ->
                gname = prop.name

                if not hasOwn.call @ejs_globals, gname
                        throw new ReferenceError "unknown identifier `#{gname}' at line #{prop.loc.start.line}"
                        
                if @options.frozen_global
                        return ir.createLoad @ejs_globals[prop.name], "load-#{gname}"

                pname = @getAtom gname
