diff options
Diffstat (limited to '')
-rw-r--r-- | source/lux/codata/lazy.lux | 6 | ||||
-rw-r--r-- | source/lux/data/io.lux | 4 |
2 files changed, 8 insertions, 2 deletions
diff --git a/source/lux/codata/lazy.lux b/source/lux/codata/lazy.lux index 1529c0dae..fb0c0bcb3 100644 --- a/source/lux/codata/lazy.lux +++ b/source/lux/codata/lazy.lux @@ -32,6 +32,12 @@ (-> (Lazy a) a)) (thunk id)) +(def #export (call/cc f) + (All [a b c] (Lazy (-> a (Lazy b c)) (Lazy a c))) + (lambda [k] + (f (lambda [a _] (k a)) + k))) + ## [Structs] (defstruct #export Lazy/Functor (Functor Lazy) (def (map f ma) diff --git a/source/lux/data/io.lux b/source/lux/data/io.lux index 2d2a2bc35..1ca68f518 100644 --- a/source/lux/data/io.lux +++ b/source/lux/data/io.lux @@ -42,10 +42,10 @@ ## [Functions] (def #export (print x) (-> Text (IO (,))) - (io (_jvm_invokevirtual "java.io.PrintStream" "print" ["java.lang.Object"] + (io (_jvm_invokevirtual "java.io.PrintStream" "print" ["java.lang.String"] (_jvm_getstatic "java.lang.System" "out") [x]))) (def #export (println x) (-> Text (IO (,))) - (io (_jvm_invokevirtual "java.io.PrintStream" "println" ["java.lang.Object"] + (io (_jvm_invokevirtual "java.io.PrintStream" "println" ["java.lang.String"] (_jvm_getstatic "java.lang.System" "out") [x]))) |