Permalink
Browse files

added loop break and continue

  • Loading branch information...
1 parent 328ae94 commit e73b64b90e3a3a8eecd3b6709c117a8607ab69c1 @snoury snoury committed Oct 7, 2010
Showing with 9 additions and 1 deletion.
  1. +9 −1 src/penumbra/translate/c.clj
@@ -296,6 +296,14 @@
[x]
(str "return " (parse (second x))))
+(defmethod parser 'break
+ [x]
+ (str "break;\n"))
+
+(defmethod parser 'continue
+ [x]
+ (str "continue;\n"))
+
(defmethod parser 'scope
[x]
(str "{\n" (indent (parse-lines (next x) ";")) "}\n"))
@@ -327,4 +335,4 @@
(list*
(first x) (second x) (third x)
(vec (map #(add-meta % :assignment true, :defines %) (fourth x)))
- (drop 4 x)))
+ (drop 4 x)))

0 comments on commit e73b64b

Please sign in to comment.