on master help sign in
Fix JS code generation

It seems JSError doesn't like the newline.

commit052e3beda690ec9fad2d0b67c9cfd2e957ba5c8b authorEdwin Brady <ecb10@st-andrews.ac.uk> dateMon 22 Dec 2014, 08:42 (12 years ago) parent5faaba9
2 files changed+2−2
src/IRTS/CodegenC.hs+1−1 src/Idris/Elab/Clause.hs+1−1
src/IRTS/CodegenC.hs+1−1
@@ -270,7 +270,7 @@ bcc i (FOREIGNCALL l LANG_C rty fn args)
270270 (fn ++ "(" ++ showSep "," (map fcall args) ++ ")") ++ ";\n"
271271 where fcall (t, arg) = irts_c t (creg arg)
272272bcc i (NULL r) = indent i ++ creg r ++ " = NULL;\n" -- clear, so it'll be GCed
273−bcc i (ERROR str) = indent i ++ "fprintf(stderr, " ++ show str ++ "); exit(-1); exit(-1);"
273+bcc i (ERROR str) = indent i ++ "fprintf(stderr, " ++ show str ++ "); fprintf(stderr, \"\\n\"); exit(-1); exit(-1);"
274274-- bcc i _ = indent i ++ "// not done yet\n"
275275
276276
src/Idris/Elab/Clause.hs+1−1
@@ -210,7 +210,7 @@ elabClauses info' fc opts n_in cs =
210210 else UnmatchedCase $ "*** " ++
211211 show fc ++
212212 ":unmatched case in " ++ show n ++
213− " ***\n"
213+ " ***"
214214
215215 tree' <- tclift $ simpleCase tcase defaultcase reflect
216216 RunTime fc inacc atys pdef' erInfo