                                 declarations: [{
                                         type: VariableDeclarator,
                                         id:   import_tmp
-                                        init: create_intrinsic(moduleGet_id, [n.source])
+                                        init: create_intrinsic(moduleGet_id, [n.source_path])
                                 }],
                                 kind: "let"
                         }
-                             
+
+                        export_stuff = []                             
                         if n.default
                                 # export * from "foo"
                                 throw new SyntaxError("invalid export") if n.specifiers.length isnt 1 or n.specifiers[0].type isnt ExportBatchSpecifier

                        declarations: [{
                                type: VariableDeclarator,
                                id:   import_tmp
                                init: create_intrinsic(moduleGet_id, [n.source])
                        }],
                        kind: "let"
                }

                throw new Error("internal compiler error, only form \"import blah from 'blah'\" supported") if specifiers.length isnt 1
                specifiers[0].id

        define_export_property = (exported_id, local_id = exported_id) ->
                console.log "exporting #{local_id.name} as #{exported_id.name}"
                exports_id = create_identifier("exports") # XXX as with compiler.coffee, this 'exports' should be '%exports' if the module has ES6 module declarations

                Object_defineProperty = {
                        type: MemberExpression,
                        computed: false,
                        object: create_identifier("Object"),
                        property: create_identifier("defineProperty")
                }

                getter = {
                        type: FunctionExpression,
                        params: [],
                        defaults: [],
                        body:
                                type: BlockStatement
                                body: [
                                        { type: ReturnStatement, argument: local_id }
                                ]
                }
                        
                property_literal = {
                        type: ObjectExpression,
                        properties: [
                                { type: Property, kind: "init", key: create_identifier("get"), value: getter }
                        ]
                }

                return {
                        type: ExpressionStatement,
                        expression: {
                                type: CallExpression
                                callee: Object_defineProperty,
                                arguments: [
                                        exports_id,
                                        create_string_literal(exported_id.name),
                                        property_literal
                                ]
                        }
                }
                
                
        visitFunction: (n) ->
                return n if not n.toplevel
                
                @exports = []
                @batch_exports = []

                super
                
        visitImportDeclaration: (n) ->
                if n.specifiers.length is 0
                        # no specifiers, it's of the form:  import from "foo"
                        # don't waste a decl for this type
                        return create_intrinsic(moduleGet_id, [n.source_path])

                # otherwise create a fresh declaration for the module object
                # 
