aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEduardo Julian2014-12-07 19:55:45 -0400
committerEduardo Julian2014-12-07 19:55:45 -0400
commit0dbcec8e727511d71101a705972eb252eec79b9f (patch)
treeae2ea455e7bbe433ec83c90d1f9f9e4742175210
parent98b427b8835eca42c0ee401a4deb842a9445a737 (diff)
Fixed bug that was causing function-calls to fail.
-rw-r--r--src/lang/compiler.clj6
-rw-r--r--test2.lang2
2 files changed, 5 insertions, 3 deletions
diff --git a/src/lang/compiler.clj b/src/lang/compiler.clj
index 1c3f634cc..66e50a462 100644
--- a/src/lang/compiler.clj
+++ b/src/lang/compiler.clj
@@ -54,7 +54,9 @@
(defcompiler ^:private compile-ident
[::&parser/ident ?name]
(doto *writer*
- (.visitVarInsn Opcodes/ALOAD (int 0))))
+ (.visitVarInsn Opcodes/ALOAD (int 0)))
+ ;; nil
+ )
(defcompiler ^:private compile-fn-call
[::&parser/fn-call [::&parser/ident ?fn] ?args]
@@ -77,7 +79,7 @@
(compile-form *writer* arg))
?method))]
(doto *writer*
- (.visitMethodInsn Opcodes/INVOKEVIRTUAL (->class "java.io.PrintStream") method "(Ljava/lang/String;)V"))))
+ (.visitMethodInsn Opcodes/INVOKEVIRTUAL (->class "java.io.PrintStream") method "(Ljava/lang/Object;)V"))))
(defcompiler ^:private compile-ann-class
[::&parser/ann-class ?class ?members]
diff --git a/test2.lang b/test2.lang
index feb3adc3f..2109ea20c 100644
--- a/test2.lang
+++ b/test2.lang
@@ -14,5 +14,5 @@
(def (main args)
(if true
- (_. (_.. java.lang.System out) (println "TRUE"))
+ (_. (_.. java.lang.System out) (println (id "YOLO")))
(_. (_.. java.lang.System out) (println "FALSE"))))