aboutsummaryrefslogtreecommitdiff
path: root/stdlib/source
diff options
context:
space:
mode:
authorEduardo Julian2018-12-04 20:29:08 -0400
committerEduardo Julian2018-12-04 20:29:08 -0400
commit03f7f28bcfcd814091537a32dd5c11a388da273b (patch)
treea817c811212d6683fb859e3e5df754349d8b4f9c /stdlib/source
parent169cb88b8ec774868ce8befbc0ccb2be6a91aa73 (diff)
Some refactoring and small fixes.
Diffstat (limited to '')
-rw-r--r--stdlib/source/lux/cli.lux7
-rw-r--r--stdlib/source/lux/concurrency/atom.lux5
-rw-r--r--stdlib/source/lux/concurrency/process.lux5
-rw-r--r--stdlib/source/lux/concurrency/stm.lux5
-rw-r--r--stdlib/source/lux/control/thread.lux5
-rw-r--r--stdlib/source/lux/data/collection/array.lux5
-rw-r--r--stdlib/source/lux/data/text.lux5
7 files changed, 23 insertions, 14 deletions
diff --git a/stdlib/source/lux/cli.lux b/stdlib/source/lux/cli.lux
index 043519111..0ac9ff0bd 100644
--- a/stdlib/source/lux/cli.lux
+++ b/stdlib/source/lux/cli.lux
@@ -12,8 +12,9 @@
[macro (#+ with-gensyms)
["." code]
["s" syntax (#+ syntax: Syntax)]]
- [compiler
- ["." host]]
+ [platform
+ [compiler
+ ["." host]]]
["." io]
[concurrency
["." process]]])
@@ -28,7 +29,7 @@
(All [a] (-> (List Text) (CLI a) (E.Error a)))
(case (p.run inputs parser)
(#E.Success [remaining output])
- (case remaining
+ (case remaining
#.Nil
(#E.Success output)
diff --git a/stdlib/source/lux/concurrency/atom.lux b/stdlib/source/lux/concurrency/atom.lux
index 2df357124..b1692b6e3 100644
--- a/stdlib/source/lux/concurrency/atom.lux
+++ b/stdlib/source/lux/concurrency/atom.lux
@@ -6,8 +6,9 @@
["." io (#- run)]
[type
abstract]
- [compiler
- ["." host]]
+ [platform
+ [compiler
+ ["." host]]]
[host (#+ import:)]])
(`` (for {(~~ (static host.jvm))
diff --git a/stdlib/source/lux/concurrency/process.lux b/stdlib/source/lux/concurrency/process.lux
index e63aba14d..c2b519fb4 100644
--- a/stdlib/source/lux/concurrency/process.lux
+++ b/stdlib/source/lux/concurrency/process.lux
@@ -6,8 +6,9 @@
[data
[collection
["." list]]]
- [compiler
- ["." host]]
+ [platform
+ [compiler
+ ["." host]]]
["." io (#+ IO io)]
[host (#+ import: object)]]
[//
diff --git a/stdlib/source/lux/concurrency/stm.lux b/stdlib/source/lux/concurrency/stm.lux
index 3c6691acc..648d86d95 100644
--- a/stdlib/source/lux/concurrency/stm.lux
+++ b/stdlib/source/lux/concurrency/stm.lux
@@ -17,10 +17,13 @@
[type
abstract]])
+(type: #export (Observer a)
+ (-> a (IO Any)))
+
(abstract: #export (Var a)
{#.doc "A mutable cell containing a value, and observers that will be alerted of any change to it."}
- (Atom [a (List (-> a (IO Any)))])
+ (Atom [a (List (Observer a))])
(def: #export (var value)
{#.doc "Creates a new STM var, with a default value."}
diff --git a/stdlib/source/lux/control/thread.lux b/stdlib/source/lux/control/thread.lux
index f81877a2a..9aad8aca0 100644
--- a/stdlib/source/lux/control/thread.lux
+++ b/stdlib/source/lux/control/thread.lux
@@ -9,8 +9,9 @@
["." array (#+ Array)]]]
[type (#+ :share)
abstract]
- [compiler
- ["." host]]
+ [platform
+ [compiler
+ ["." host]]]
[io (#+ IO)]])
(type: #export (Thread ! a)
diff --git a/stdlib/source/lux/data/collection/array.lux b/stdlib/source/lux/data/collection/array.lux
index 339e4e7ca..c38ae1371 100644
--- a/stdlib/source/lux/data/collection/array.lux
+++ b/stdlib/source/lux/data/collection/array.lux
@@ -11,8 +11,9 @@
["." maybe]
[collection
["." list ("list/." Fold<List>)]]]
- [compiler
- ["." host]]])
+ [platform
+ [compiler
+ ["." host]]]])
(def: #export array-type-name "#Array")
diff --git a/stdlib/source/lux/data/text.lux b/stdlib/source/lux/data/text.lux
index 2cd6f7980..6c427f151 100644
--- a/stdlib/source/lux/data/text.lux
+++ b/stdlib/source/lux/data/text.lux
@@ -13,8 +13,9 @@
["." i64]]
[collection
["." list ("list/." Fold<List>)]]]
- [compiler
- ["." host]]])
+ [platform
+ [compiler
+ ["." host]]]])
(type: #export Char Nat)