diff options
author | Eduardo Julian | 2015-07-12 21:04:56 -0400 |
---|---|---|
committer | Eduardo Julian | 2015-07-12 21:04:56 -0400 |
commit | 658ff3e1e7d90ce72c8a02ef4cf7e177d8ac6f86 (patch) | |
tree | 4ee6b9c0727a7619b1ebb2a50c9db17ada6a35c0 /input/program.lux | |
parent | e351122010b5eb5bf8793382a4a4ddcf5fb3a386 (diff) |
- Added the beginnings of the standard library.
- Fixed several bugs.
Diffstat (limited to 'input/program.lux')
-rw-r--r-- | input/program.lux | 39 |
1 files changed, 26 insertions, 13 deletions
diff --git a/input/program.lux b/input/program.lux index 4f329c3fa..6495854c1 100644 --- a/input/program.lux +++ b/input/program.lux @@ -1,15 +1,28 @@ -(;lux) - -(def (filter p xs) - (All [a] (-> (-> a Bool) (List a) (List a))) - (case xs - #;Nil - (list) - - (#;Cons [x xs']) - (if (p x) - (list& x (filter p xs')) - (filter p xs')))) +(;import lux + (lux (control monoid + functor + monad + lazy + comonad) + (data eq + bounded + ord + io + list + state + number + (text #as t) + dict + show) + (codata (stream #refer (#except iterate))) + (meta lux + macro + syntax))) (_jvm_program args - (println "Hello, world!")) + (case args + #;Nil + (println "Hello, world!") + + (#;Cons [name _]) + (println ($ text:++ "Hello, " name "!")))) |