From ab7b946a980475cad1e58186ac8c929c7659f529 Mon Sep 17 00:00:00 2001 From: Eduardo Julian Date: Sun, 10 May 2015 10:37:06 -0400 Subject: - Now analysing function-application backwards. --- source/program.lux | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'source/program.lux') diff --git a/source/program.lux b/source/program.lux index 22bbad2d5..2bbf3fd4f 100644 --- a/source/program.lux +++ b/source/program.lux @@ -13,6 +13,6 @@ (jvm-program _ (exec (println "Hello, world!") - (println ($ text:++ "2 + 2 = " (->text (int:+ 2 2)))) - (println (->text (using Int:Ord - (< 5 10)))))) + (|> (int:+ 2 2) ->text ($ text:++ "2 + 2 = ") println) + (println (->text (using Int:Ord + (< 5 10)))))) -- cgit v1.2.3 From 8dc736e2a383fe964d63dda6b885d41cabc6261c Mon Sep 17 00:00:00 2001 From: Eduardo Julian Date: Sun, 10 May 2015 15:04:36 -0400 Subject: - Switched to the new prefix convention for both lux's special forms and the host's. - Made a few optimizations to speed-up the now slowed-down compiler. --- source/program.lux | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'source/program.lux') diff --git a/source/program.lux b/source/program.lux index 2bbf3fd4f..20f7863ab 100644 --- a/source/program.lux +++ b/source/program.lux @@ -11,8 +11,8 @@ (list& x (filter p xs')) (filter p xs')))) -(jvm-program _ - (exec (println "Hello, world!") - (|> (int:+ 2 2) ->text ($ text:++ "2 + 2 = ") println) - (println (->text (using Int:Ord - (< 5 10)))))) +(_jvm_program _ + (exec (println "Hello, world!") + (|> (int:+ 2 2) ->text ($ text:++ "2 + 2 = ") println) + (println (->text (using Int:Ord + (< 5 10)))))) -- cgit v1.2.3 From c4ac3e692ae96d6898d8efb42faf4dfadd43f4ae Mon Sep 17 00:00:00 2001 From: Eduardo Julian Date: Thu, 14 May 2015 08:23:10 -0400 Subject: - Removed the apparently unnecessary total-locals. --- source/program.lux | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'source/program.lux') diff --git a/source/program.lux b/source/program.lux index 20f7863ab..a9451580f 100644 --- a/source/program.lux +++ b/source/program.lux @@ -1,4 +1,4 @@ -(;alias-lux) +(;lux) (def (filter p xs) (All [a] (-> (-> a Bool) (List a) (List a))) -- cgit v1.2.3 From f52eb6df2e57f67e7cf30d85c6340ce00f923d6f Mon Sep 17 00:00:00 2001 From: Eduardo Julian Date: Fri, 22 May 2015 20:07:08 -0400 Subject: - Corrected the indentation issues in the lux files. - Temporarily reverted back to forward apply-analysis. - Fixed an error in lux.base/show-ast. - Reader now only returns a tuple instead of a full-blown #Meta variant. - Reader now doesn't cut the strings that it reads. Instead, the "cursor" just moves around, indicating where to read. - Inlined some calculations that previously relied on try-all%. --- source/program.lux | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'source/program.lux') diff --git a/source/program.lux b/source/program.lux index a9451580f..cefec07d4 100644 --- a/source/program.lux +++ b/source/program.lux @@ -12,7 +12,7 @@ (filter p xs')))) (_jvm_program _ - (exec (println "Hello, world!") - (|> (int:+ 2 2) ->text ($ text:++ "2 + 2 = ") println) - (println (->text (using Int:Ord - (< 5 10)))))) + (exec (println "Hello, world!") + (|> (int:+ 2 2) ->text ($ text:++ "2 + 2 = ") println) + (println (->text (using Int:Ord + (< 5 10)))))) -- cgit v1.2.3 From 5e45ec0419293fdde30cc9e3f0326e44ddd7442a Mon Sep 17 00:00:00 2001 From: Eduardo Julian Date: Wed, 27 May 2015 00:57:57 -0400 Subject: - _jvm_program now relies on the (IO (,)) type. - The command-line params argument in jvm_program is now transformed from a String array into (List Text). --- source/program.lux | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'source/program.lux') diff --git a/source/program.lux b/source/program.lux index cefec07d4..364c57d89 100644 --- a/source/program.lux +++ b/source/program.lux @@ -12,7 +12,4 @@ (filter p xs')))) (_jvm_program _ - (exec (println "Hello, world!") - (|> (int:+ 2 2) ->text ($ text:++ "2 + 2 = ") println) - (println (->text (using Int:Ord - (< 5 10)))))) + (println "Hello, world!")) -- cgit v1.2.3 From 5e9e876131901204dd34ce1548a4df3cb6cba95f Mon Sep 17 00:00:00 2001 From: Eduardo Julian Date: Sat, 20 Jun 2015 20:19:02 -0400 Subject: - The directory for source-code is now named "input". - Implemented module-caching to avoid the waiting too much during program compilation. --- source/program.lux | 15 --------------- 1 file changed, 15 deletions(-) delete mode 100644 source/program.lux (limited to 'source/program.lux') diff --git a/source/program.lux b/source/program.lux deleted file mode 100644 index 364c57d89..000000000 --- a/source/program.lux +++ /dev/null @@ -1,15 +0,0 @@ -(;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')))) - -(_jvm_program _ - (println "Hello, world!")) -- cgit v1.2.3 From 4cd9b0c9242f1105e50ad9b42b7f6f5d074f14b4 Mon Sep 17 00:00:00 2001 From: Eduardo Julian Date: Sat, 25 Jul 2015 20:19:43 -0400 Subject: - The output directory is now being used as the cache. - "input" has been renamed as "source" and "output" has been renamed as "target". --- source/program.lux | 48 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 source/program.lux (limited to 'source/program.lux') diff --git a/source/program.lux b/source/program.lux new file mode 100644 index 000000000..052c0bf41 --- /dev/null +++ b/source/program.lux @@ -0,0 +1,48 @@ +## Copyright (c) Eduardo Julian. All rights reserved. +## The use and distribution terms for this software are covered by the +## Eclipse Public License 1.0 (http://opensource.org/licenses/eclipse-1.0.php) +## which can be found in the file epl-v10.html at the root of this distribution. +## By using this software in any fashion, you are agreeing to be bound by +## the terms of this license. +## You must not remove this notice, or any other, from this software. + +(;import lux + (lux (codata (stream #as S)) + (control monoid + functor + monad + lazy + comonad) + (data bool + bounded + char + ## cont + dict + (either #as e) + eq + error + id + io + list + maybe + number + ord + (reader #as r) + show + state + (text #as t) + writer) + (host java) + (meta lux + macro + syntax) + (math #as m) + )) + +(program args + (case args + #;Nil + (println "Hello, world!") + + (#;Cons [name _]) + (println ($ text:++ "Hello, " name "!")))) -- cgit v1.2.3 From 9b7cfd6f5bcc93e2f2f0c3129b7ec6d62c69bb37 Mon Sep 17 00:00:00 2001 From: Eduardo Julian Date: Sun, 26 Jul 2015 20:57:21 -0400 Subject: - Fixed a pattern-matching error where generalizations of types (universal-quantification / AllT) was not being taken into account properly when destructuring. - Fixed a compiler error wherein the types of definitions didn't generate (correctly) the structures necessary for storage inside the class _meta(data) field. - Improved both the "open" and "import" macros with extra features. --- source/program.lux | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'source/program.lux') diff --git a/source/program.lux b/source/program.lux index 052c0bf41..18a2a76ab 100644 --- a/source/program.lux +++ b/source/program.lux @@ -30,7 +30,7 @@ (reader #as r) show state - (text #as t) + (text #as t #open ("text:" Text/Monoid)) writer) (host java) (meta lux -- cgit v1.2.3 From 8fb7683f9029127be9cf36336c367813c88f681b Mon Sep 17 00:00:00 2001 From: Eduardo Julian Date: Sun, 26 Jul 2015 23:09:47 -0400 Subject: - Changed the name of lux/host/java to lux/host/jvm - Completed lux/host/jvm - Modified (slightly) the syntax used in several host (JVM) special forms. - The "defsyntax" macro now binds all of the arguments it receives inside a variable named "tokens". --- source/program.lux | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'source/program.lux') diff --git a/source/program.lux b/source/program.lux index 18a2a76ab..37391eda9 100644 --- a/source/program.lux +++ b/source/program.lux @@ -32,7 +32,7 @@ state (text #as t #open ("text:" Text/Monoid)) writer) - (host java) + (host jvm) (meta lux macro syntax) -- cgit v1.2.3 From c79621772c862e9b94e1fc43e11996cbac54fed1 Mon Sep 17 00:00:00 2001 From: Eduardo Julian Date: Wed, 29 Jul 2015 20:20:26 -0400 Subject: - lux;using no longer prefixes variables. - Fixed several bugs with host (JVM) interop. - Now packaging everything in a .jar file ("program.jar"). --- source/program.lux | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'source/program.lux') diff --git a/source/program.lux b/source/program.lux index 37391eda9..086506725 100644 --- a/source/program.lux +++ b/source/program.lux @@ -41,8 +41,8 @@ (program args (case args - #;Nil - (println "Hello, world!") - - (#;Cons [name _]) - (println ($ text:++ "Hello, " name "!")))) + (\ (list name)) + (println ($ text:++ "Hello, " name "!")) + + _ + (println "Hello, world!"))) -- cgit v1.2.3