Skip to content

Commit

Permalink
CLJS-1463: (js-debugger) should generate nil-returning expression
Browse files Browse the repository at this point in the history
js-debugger macro can now be used in last position of an (implicit)
do. Previously this was not possible, because "return debugger;" was
generated, resulting in an js syntax error.
  • Loading branch information
borkdude authored and dnolen committed Dec 23, 2015
1 parent eef56c1 commit 77f089a
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/main/clojure/cljs/core.cljc
Expand Up @@ -864,9 +864,11 @@
(core/list 'js* "~{} in ~{}" key obj))

(core/defmacro js-debugger
"Emit JavaScript \"debugger;\" statement."
"Emit JavaScript \"debugger;\" statement"
[]
(core/list 'js* "debugger;"))
(core/list 'do
(core/list 'js* "debugger")
nil))

(core/defmacro js-comment
"Emit a top-level JavaScript multi-line comment. New lines will create a
Expand Down

0 comments on commit 77f089a

Please sign in to comment.