aboutsummaryrefslogtreecommitdiff
path: root/stdlib/source
diff options
context:
space:
mode:
Diffstat (limited to 'stdlib/source')
-rw-r--r--stdlib/source/library/lux/control/concurrency/actor.lux2
-rw-r--r--stdlib/source/library/lux/control/concurrency/thread.lux2
-rw-r--r--stdlib/source/library/lux/ffi.jvm.lux10
-rw-r--r--stdlib/source/library/lux/ffi.old.lux10
-rw-r--r--stdlib/source/library/lux/target/jvm/loader.lux2
-rw-r--r--stdlib/source/test/lux/control/concurrency/actor.lux6
-rw-r--r--stdlib/source/test/lux/ffi.jvm.lux59
-rw-r--r--stdlib/source/test/lux/ffi.old.lux12
8 files changed, 55 insertions, 48 deletions
diff --git a/stdlib/source/library/lux/control/concurrency/actor.lux b/stdlib/source/library/lux/control/concurrency/actor.lux
index 617068a4c..5ce45f632 100644
--- a/stdlib/source/library/lux/control/concurrency/actor.lux
+++ b/stdlib/source/library/lux/control/concurrency/actor.lux
@@ -276,7 +276,7 @@
(~+ messages)])))))))
-(syntax: .public (actor [[state_type init] (<code>.record (<>.and <code>.any <code>.any))
+(syntax: .public (actor [[state_type init] (<code>.tuple (<>.and <code>.any <code>.any))
?on_mail on_mail^])
(with_identifiers [g!_]
(in (list (` (: ((~! io.IO) (..Actor (~ state_type)))
diff --git a/stdlib/source/library/lux/control/concurrency/thread.lux b/stdlib/source/library/lux/control/concurrency/thread.lux
index b0571cc64..4e82d76a6 100644
--- a/stdlib/source/library/lux/control/concurrency/thread.lux
+++ b/stdlib/source/library/lux/control/concurrency/thread.lux
@@ -105,7 +105,7 @@
(-> Nat (IO Any) (IO Any))
(with_expansions [<jvm> (as_is (let [runnable (ffi.object [] [java/lang/Runnable]
[]
- (java/lang/Runnable [] (run self) void
+ (java/lang/Runnable [] (run self []) void
(..execute! action)))]
(case milli_seconds
0 (java/util/concurrent/Executor::execute runnable runner)
diff --git a/stdlib/source/library/lux/ffi.jvm.lux b/stdlib/source/library/lux/ffi.jvm.lux
index b71944646..8b7ba8911 100644
--- a/stdlib/source/library/lux/ffi.jvm.lux
+++ b/stdlib/source/library/lux/ffi.jvm.lux
@@ -706,7 +706,7 @@
(def: annotation_parameters^
(Parser (List Annotation_Parameter))
- (<code>.record (<>.some (<>.and <code>.local_tag <code>.any))))
+ (<code>.tuple (<>.some (<>.and <code>.local_tag <code>.any))))
(def: annotation^
(Parser Annotation)
@@ -771,16 +771,16 @@
(def: (argument^ type_vars)
(-> (List (Type Var)) (Parser Argument))
- (<code>.record (<>.and <code>.local_identifier
- (..type^ type_vars))))
+ (<>.and <code>.local_identifier
+ (..type^ type_vars)))
(def: (arguments^ type_vars)
(-> (List (Type Var)) (Parser (List Argument)))
- (<>.some (..argument^ type_vars)))
+ (<code>.tuple (<>.some (..argument^ type_vars))))
(def: (constructor_arg^ type_vars)
(-> (List (Type Var)) (Parser (Typed Code)))
- (<code>.record (<>.and (..type^ type_vars) <code>.any)))
+ (<>.and (..type^ type_vars) <code>.any))
(def: (constructor_args^ type_vars)
(-> (List (Type Var)) (Parser (List (Typed Code))))
diff --git a/stdlib/source/library/lux/ffi.old.lux b/stdlib/source/library/lux/ffi.old.lux
index c24e49deb..f62581e68 100644
--- a/stdlib/source/library/lux/ffi.old.lux
+++ b/stdlib/source/library/lux/ffi.old.lux
@@ -643,7 +643,7 @@
(def: annotation_params^
(Parser (List AnnotationParam))
- (<code>.record (<>.some (<>.and <code>.local_tag <code>.any))))
+ (<code>.tuple (<>.some (<>.and <code>.local_tag <code>.any))))
(def: annotation^
(Parser Annotation)
@@ -717,16 +717,16 @@
(def: (arg_decl^ type_vars)
(-> (List Type_Parameter) (Parser ArgDecl))
- (<code>.record (<>.and <code>.local_identifier
- (..generic_type^ type_vars))))
+ (<>.and <code>.local_identifier
+ (..generic_type^ type_vars)))
(def: (arg_decls^ type_vars)
(-> (List Type_Parameter) (Parser (List ArgDecl)))
- (<>.some (arg_decl^ type_vars)))
+ (<code>.tuple (<>.some (arg_decl^ type_vars))))
(def: (constructor_arg^ type_vars)
(-> (List Type_Parameter) (Parser ConstructorArg))
- (<code>.record (<>.and (..generic_type^ type_vars) <code>.any)))
+ (<>.and (..generic_type^ type_vars) <code>.any))
(def: (constructor_args^ type_vars)
(-> (List Type_Parameter) (Parser (List ConstructorArg)))
diff --git a/stdlib/source/library/lux/target/jvm/loader.lux b/stdlib/source/library/lux/target/jvm/loader.lux
index 596e57dab..fe2bba2e6 100644
--- a/stdlib/source/library/lux/target/jvm/loader.lux
+++ b/stdlib/source/library/lux/target/jvm/loader.lux
@@ -110,7 +110,7 @@
(<| <cast>
(object [] java/lang/ClassLoader []
[]
- (java/lang/ClassLoader (findClass self {class_name java/lang/String})
+ (java/lang/ClassLoader (findClass self [class_name java/lang/String])
(java/lang/Class [? < java/lang/Object])
"throws" [java/lang/ClassNotFoundException]
(let [class_name (:as Text class_name)
diff --git a/stdlib/source/test/lux/control/concurrency/actor.lux b/stdlib/source/test/lux/control/concurrency/actor.lux
index 012a9f796..27b13bba4 100644
--- a/stdlib/source/test/lux/control/concurrency/actor.lux
+++ b/stdlib/source/test/lux/control/concurrency/actor.lux
@@ -175,8 +175,8 @@
(in (do async.monad
[verdict (async.future
(do io.monad
- [anonymous (/.actor {Nat
- initial_state}
+ [anonymous (/.actor [Nat
+ initial_state]
((on_mail message state self)
(message (++ state) self)))
sent/++? (/.mail! ++! anonymous)
@@ -207,7 +207,7 @@
(in (do async.monad
[agent (async.future
(do [! io.monad]
- [agent (/.actor {Nat 0})
+ [agent (/.actor [Nat 0])
_ (/.observe! (function (_ event stop)
(function (_ events_seen self)
(async.future
diff --git a/stdlib/source/test/lux/ffi.jvm.lux b/stdlib/source/test/lux/ffi.jvm.lux
index 606bd8a23..431e72641 100644
--- a/stdlib/source/test/lux/ffi.jvm.lux
+++ b/stdlib/source/test/lux/ffi.jvm.lux
@@ -267,7 +267,7 @@
.let [object/0 (/.object [] [test/TestInterface0]
[]
(test/TestInterface0
- [] (actual0 self)
+ [] (actual0 self [])
java/lang/Long
(:as java/lang/Long
expected)))
@@ -278,7 +278,7 @@
object/1 (/.object [] [test/TestInterface1]
[]
(test/TestInterface1
- [] (actual1 self {throw? java/lang/Boolean})
+ [] (actual1 self [throw? java/lang/Boolean])
java/lang/Long
"throws" [java/lang/Throwable]
(if (:as Bit throw?)
@@ -303,7 +303,7 @@
object/2 (/.object [] [test/TestInterface2]
[]
(test/TestInterface2
- [a] (actual2 self {input a})
+ [a] (actual2 self [input a])
a
input))
example/2!
@@ -313,7 +313,7 @@
object/3 (/.object [] [(test/TestInterface3 java/lang/Long)]
[]
((test/TestInterface3 a)
- [] (actual3 self)
+ [] (actual3 self [])
a
(:as java/lang/Long
expected)))
@@ -326,7 +326,9 @@
object/4 (/.object [] [test/TestInterface4]
[]
(test/TestInterface4
- [] (actual4 self {actual_left long} {actual_right long} {_ long})
+ [] (actual4 self [actual_left long
+ actual_right long
+ _ long])
long
(:as java/lang/Long
(i.+ (:as Int actual_left)
@@ -344,10 +346,11 @@
... Fields
("private" value java/lang/Long)
... Constructors
- ("public" [] (new self {value java/lang/Long}) []
+ ("public" [] (new self [value java/lang/Long]) []
(:= ::value value))
... Methods
- (test/TestInterface0 [] (actual0 self) java/lang/Long
+ (test/TestInterface0 [] (actual0 self [])
+ java/lang/Long
::value))
(/.import: test/TestClass0
@@ -358,10 +361,12 @@
... Fields
("private" value java/lang/Long)
... Constructors
- ("public" [] (new self {value java/lang/Long}) []
+ ("public" [] (new self [value java/lang/Long]) []
(:= ::value value))
... Methods
- (test/TestInterface1 [] (actual1 self {throw? java/lang/Boolean}) java/lang/Long "throws" [java/lang/Throwable]
+ (test/TestInterface1 [] (actual1 self [throw? java/lang/Boolean])
+ java/lang/Long
+ "throws" [java/lang/Throwable]
(if (:as Bit throw?)
(panic! "YOLO")
::value)))
@@ -372,11 +377,11 @@
(/.class: "final" test/TestClass2 [test/TestInterface2]
... Constructors
- ("public" [] (new self) []
+ ("public" [] (new self []) []
[])
... Methods
(test/TestInterface2
- [a] (actual2 self {input a})
+ [a] (actual2 self [input a])
a
input))
@@ -388,11 +393,11 @@
... Fields
("private" value a)
... Constructors
- ("public" [] (new self {value a}) []
+ ("public" [] (new self [value a]) []
(:= ::value value))
... Methods
((test/TestInterface3 a)
- [] (actual3 self)
+ [] (actual3 self [])
a
::value))
@@ -402,10 +407,10 @@
(/.class: "final" test/TestClass4 []
... Constructors
- ("public" [] (new self) []
+ ("public" [] (new self []) []
[])
... Methods
- ("public" (actual4 self {value java/lang/Long}) java/lang/Long
+ ("public" (actual4 self [value java/lang/Long]) java/lang/Long
value))
(/.import: test/TestClass4
@@ -415,10 +420,10 @@
(/.class: "final" test/TestClass5 []
... Constructors
- ("public" [] (new self) []
+ ("public" [] (new self []) []
[])
... Methods
- ("public" "static" (actual5 {value java/lang/Long})
+ ("public" "static" (actual5 [value java/lang/Long])
java/lang/Long
value))
@@ -428,10 +433,10 @@
(/.class: "abstract" test/TestClass6 []
... Constructors
- ("public" [] (new self) []
+ ("public" [] (new self []) []
[])
... Methods
- ("public" "abstract" (actual6 {value java/lang/Long})
+ ("public" "abstract" (actual6 [value java/lang/Long])
java/lang/Long))
(/.import: test/TestClass6
@@ -440,11 +445,11 @@
(/.class: "final" test/TestClass7 test/TestClass6 []
... Constructors
- ("public" [] (new self) []
+ ("public" [] (new self []) []
[])
... Methods
(test/TestClass6
- [] (actual6 self {input java/lang/Long})
+ [] (actual6 self [input java/lang/Long])
java/lang/Long
input))
@@ -454,11 +459,13 @@
(/.class: "final" test/TestClass8 [test/TestInterface4]
... Constructors
- ("public" [] (new self) []
+ ("public" [] (new self []) []
[])
... Methods
(test/TestInterface4
- [] (actual4 self {actual_left long} {actual_right long} {_ long})
+ [] (actual4 self [actual_left long
+ actual_right long
+ _ long])
long
(:as java/lang/Long
(i.+ (:as Int actual_left)
@@ -472,12 +479,12 @@
... Fields
("private" value9 a)
... Constructors
- ("public" [] (new self {value a}) []
+ ("public" [] (new self [value a]) []
(:= ::value9 value))
... Methods
- ("public" (set_actual9 self {value a}) void
+ ("public" (set_actual9 self [value a]) void
(:= ::value9 value))
- ("public" (get_actual9 self) a
+ ("public" (get_actual9 self []) a
::value9))
(/.import: (test/TestClass9 a)
diff --git a/stdlib/source/test/lux/ffi.old.lux b/stdlib/source/test/lux/ffi.old.lux
index 56f97a962..27d18d002 100644
--- a/stdlib/source/test/lux/ffi.old.lux
+++ b/stdlib/source/test/lux/ffi.old.lux
@@ -43,11 +43,11 @@
(:= ::increase increase)
(:= ::counter counter)
[]))
- ("public" (currentC self) java/lang/Long
+ ("public" (currentC self []) java/lang/Long
::counter)
- ("public" (upC self) void
+ ("public" (upC self []) void
(:= ::counter (i.+ ::increase ::counter)))
- ("public" (downC self) void
+ ("public" (downC self []) void
(:= ::counter (i.- ::increase ::counter))))
(/.import: (test/lux/ffi/TestClass a)
@@ -73,15 +73,15 @@
(/.object [] [test/lux/ffi/TestInterface]
[]
(test/lux/ffi/TestInterface
- [] (current self)
+ [] (current self [])
java/lang/Long
counter)
(test/lux/ffi/TestInterface
- [] (up self)
+ [] (up self [])
test/lux/ffi/TestInterface
(test_object increase (i.+ increase counter)))
(test/lux/ffi/TestInterface
- [] (down self)
+ [] (down self [])
test/lux/ffi/TestInterface
(test_object increase (i.- increase counter)))))