on master help sign in
fix bug in loading dependencies for REPL
2a8b005Evan Czaplicki
compiler/src/Generate/JavaScript.hs+2−2
@@ -83,7 +83,7 @@ generateForRepl :: Bool -> L.Localizer -> Opt.GlobalGraph -> ModuleName.Canonica
83generateForRepl ansi localizer (Opt.GlobalGraph graph _) home name (Can.Forall _ tipe) =
83generateForRepl ansi localizer (Opt.GlobalGraph graph _) home name (Can.Forall _ tipe) =
84 let
84 let
85 mode = Mode.Dev Nothing
85 mode = Mode.Dev Nothing
86− debugState = addGlobal mode graph emptyState (Opt.Global ModuleName.debug "toAnsiString")
86+ debugState = addGlobal mode graph emptyState (Opt.Global ModuleName.debug "toString")
87 evalState = addGlobal mode graph debugState (Opt.Global home name)
87 evalState = addGlobal mode graph debugState (Opt.Global home name)
88 in
88 in
89 "process.on('uncaughtException', function(err) { process.stderr.write(err.toString() + '\\n'); process.exit(1); });"
89 "process.on('uncaughtException', function(err) { process.stderr.write(err.toString() + '\\n'); process.exit(1); });"
@@ -119,7 +119,7 @@ generateForReplEndpoint localizer (Opt.GlobalGraph graph _) home maybeName (Can.
119 let
119 let
120 name = maybe Name.replValueToPrint id maybeName
120 name = maybe Name.replValueToPrint id maybeName
121 mode = Mode.Dev Nothing
121 mode = Mode.Dev Nothing
122− debugState = addGlobal mode graph emptyState (Opt.Global ModuleName.debug "toAnsiString")
122+ debugState = addGlobal mode graph emptyState (Opt.Global ModuleName.debug "toString")
123 evalState = addGlobal mode graph debugState (Opt.Global home name)
123 evalState = addGlobal mode graph debugState (Opt.Global home name)
124 in
124 in
125 Functions.functions
125 Functions.functions