aboutsummaryrefslogtreecommitdiff
path: root/new-luxc/source/luxc
diff options
context:
space:
mode:
Diffstat (limited to 'new-luxc/source/luxc')
-rw-r--r--new-luxc/source/luxc/lang/init.lux2
-rw-r--r--new-luxc/source/luxc/lang/macro.lux2
-rw-r--r--new-luxc/source/luxc/lang/translation.lux8
-rw-r--r--new-luxc/source/luxc/lang/translation/js/imports.jvm.lux4
-rw-r--r--new-luxc/source/luxc/lang/translation/jvm/common.jvm.lux3
-rw-r--r--new-luxc/source/luxc/lang/translation/jvm/imports.jvm.lux18
-rw-r--r--new-luxc/source/luxc/repl.lux8
7 files changed, 22 insertions, 23 deletions
diff --git a/new-luxc/source/luxc/lang/init.lux b/new-luxc/source/luxc/lang/init.lux
index 73b2baf0a..da8fc9c07 100644
--- a/new-luxc/source/luxc/lang/init.lux
+++ b/new-luxc/source/luxc/lang/init.lux
@@ -34,7 +34,7 @@
#.mode #.Build})
(def: #export (compiler host)
- (-> Top Compiler)
+ (-> Top Lux)
{#.info ..info
#.source dummy-source
#.cursor .dummy-cursor
diff --git a/new-luxc/source/luxc/lang/macro.lux b/new-luxc/source/luxc/lang/macro.lux
index cde3209fc..043f0df93 100644
--- a/new-luxc/source/luxc/lang/macro.lux
+++ b/new-luxc/source/luxc/lang/macro.lux
@@ -30,6 +30,6 @@
(host.array-write +0 (:! Object inputs))
(host.array-write +1 (:! Object compiler)))]
apply-method)]
- (:! (e.Error [Compiler (List Code)])
+ (:! (e.Error [Lux (List Code)])
output))))))
})
diff --git a/new-luxc/source/luxc/lang/translation.lux b/new-luxc/source/luxc/lang/translation.lux
index cd9214885..4cab6d682 100644
--- a/new-luxc/source/luxc/lang/translation.lux
+++ b/new-luxc/source/luxc/lang/translation.lux
@@ -67,7 +67,7 @@
(wrap [annsI (:! Code annsV)])))
(def: (switch-compiler new-compiler)
- (-> Compiler (Meta Aliases))
+ (-> Lux (Meta Aliases))
(function (_ old-compiler)
((do macro.Monad<Meta>
[this macro.current-module]
@@ -75,7 +75,7 @@
new-compiler)))
(def: #export (translate translate-module aliases code)
- (-> (-> Text Compiler (Process Compiler)) Aliases Code (Meta Aliases))
+ (-> (-> Text Lux (Process Lux)) Aliases Code (Meta Aliases))
(case code
(^code ("lux module" (~ annsC)))
(do macro.Monad<Meta>
@@ -184,7 +184,7 @@
(def: no-aliases Aliases (dict.new text.Hash<Text>))
(def: #export (translate-module source-dirs target-dir module-name compiler)
- (-> (List File) File Text Compiler (Process Compiler))
+ (-> (List File) File Text Lux (Process Lux))
(do io.Monad<Process>
[[file-name file-content] (&io.read source-dirs module-name)
#let [module-hash (text/hash file-content)
@@ -241,7 +241,7 @@
))
(def: (initialize sources target)
- (-> (List File) File (Process Compiler))
+ (-> (List File) File (Process Lux))
(do io.Monad<Process>
[compiler (case (runtimeT.translate ## (initL.compiler (io.run js.init))
(initL.compiler (io.run hostL.init-host))
diff --git a/new-luxc/source/luxc/lang/translation/js/imports.jvm.lux b/new-luxc/source/luxc/lang/translation/js/imports.jvm.lux
index 64f10dabc..cbd4b2752 100644
--- a/new-luxc/source/luxc/lang/translation/js/imports.jvm.lux
+++ b/new-luxc/source/luxc/lang/translation/js/imports.jvm.lux
@@ -30,9 +30,9 @@
(def: import (s.Syntax Import) (s.tuple (p.seq s.text s.text)))
(def: #export (translate-imports translate-module annotations)
- (-> (-> Text Compiler (Process Compiler))
+ (-> (-> Text Lux (Process Lux))
Code
- (Meta (Process Compiler)))
+ (Meta (Process Lux)))
(do macro.Monad<Meta>
[_ (moduleL.set-annotations annotations)
current-module macro.current-module-name
diff --git a/new-luxc/source/luxc/lang/translation/jvm/common.jvm.lux b/new-luxc/source/luxc/lang/translation/jvm/common.jvm.lux
index 524433214..29db94d07 100644
--- a/new-luxc/source/luxc/lang/translation/jvm/common.jvm.lux
+++ b/new-luxc/source/luxc/lang/translation/jvm/common.jvm.lux
@@ -116,8 +116,7 @@
(def: #export $Object $.Type ($t.class "java.lang.Object" (list)))
(def: #export (load-definition compiler)
- (-> Compiler
- (-> Ident Blob (Error Top)))
+ (-> Lux (-> Ident Blob (Error Top)))
(function (_ (^@ def-ident [def-module def-name]) def-bytecode)
(let [normal-name (format (lang.normalize-name def-name) (%n (text/hash def-name)))
class-name (format (text.replace-all "/" "." def-module) "." normal-name)]
diff --git a/new-luxc/source/luxc/lang/translation/jvm/imports.jvm.lux b/new-luxc/source/luxc/lang/translation/jvm/imports.jvm.lux
index 44314fcf2..de75a4d75 100644
--- a/new-luxc/source/luxc/lang/translation/jvm/imports.jvm.lux
+++ b/new-luxc/source/luxc/lang/translation/jvm/imports.jvm.lux
@@ -45,7 +45,7 @@
(def: import (s.Syntax Import) (s.tuple (p.seq s.text s.text)))
(def: compilations
- (Var (Dict Text (CompletableFuture (Error Compiler))))
+ (Var (Dict Text (CompletableFuture (Error Lux))))
(stm.var (dict.new text.Hash<Text>)))
(def: (promise-to-future promise)
@@ -61,12 +61,12 @@
(:: io.Monad<IO> map (|>> #e.Success)))
(def: (translate-dependency translate-module dependency compiler)
- (-> (-> Text Compiler (Process Compiler))
- (-> Text Compiler (IO (Future (Error Compiler)))))
+ (-> (-> Text Lux (Process Lux))
+ (-> Text Lux (IO (Future (Error Lux)))))
(<| (Future::get [])
promise-to-future
(do promise.Monad<Promise>
- [[new? future] (stm.commit (: (STM [Bool (CompletableFuture (Error Compiler))])
+ [[new? future] (stm.commit (: (STM [Bool (CompletableFuture (Error Lux))])
(do stm.Monad<STM>
[current-compilations (stm.read compilations)]
(case (dict.get dependency current-compilations)
@@ -75,7 +75,7 @@
#.None
(do @
- [#let [pending (: (CompletableFuture (Error Compiler))
+ [#let [pending (: (CompletableFuture (Error Lux))
(CompletableFuture::new []))]
_ (stm.write (dict.put dependency pending current-compilations)
compilations)]
@@ -104,15 +104,15 @@
from-current)))
(def: (merge-compilers current-module dependency total)
- (-> Text Compiler Compiler Compiler)
+ (-> Text Lux Lux Lux)
(|> total
(update@ #.modules (merge-modules current-module (get@ #.modules dependency)))
(set@ #.seed (get@ #.seed dependency))))
(def: #export (translate-imports translate-module annotations)
- (-> (-> Text Compiler (Process Compiler))
+ (-> (-> Text Lux (Process Lux))
Code
- (Meta (Process Compiler)))
+ (Meta (Process Lux)))
(do macro.Monad<Meta>
[_ (moduleL.set-annotations annotations)
current-module macro.current-module-name
@@ -124,7 +124,7 @@
(#e.Error error)
(&.throw Invalid-Imports (%code (code.tuple imports)))))
- dependencies (monad.map @ (: (-> [Text Text] (Meta (IO (Future (Error Compiler)))))
+ dependencies (monad.map @ (: (-> [Text Text] (Meta (IO (Future (Error Lux)))))
(function (_ [dependency alias])
(do @
[_ (&.assert Module-Cannot-Import-Itself current-module
diff --git a/new-luxc/source/luxc/repl.lux b/new-luxc/source/luxc/repl.lux
index cdc61ab22..fbf1a336e 100644
--- a/new-luxc/source/luxc/repl.lux
+++ b/new-luxc/source/luxc/repl.lux
@@ -55,7 +55,7 @@
(def: no-aliases Aliases (dict.new text.Hash<Text>))
(def: (initialize source-dirs target-dir console)
- (-> (List File) File Console (Task Compiler))
+ (-> (List File) File Console (Task Lux))
(do promise.Monad<Promise>
[output (promise.future
(do io.Monad<IO>
@@ -200,7 +200,7 @@
(recur tail variantV)))))))))
(def: (tagged-representation compiler representation)
- (-> Compiler (Poly Representation) (Poly Representation))
+ (-> Lux (Poly Representation) (Poly Representation))
(do p.Monad<Parser>
[[name anonymous] poly.named]
(case (macro.run compiler (macro.tags-of name))
@@ -237,7 +237,7 @@
(format "[" tuple-body "]"))))))
(def: (representation compiler)
- (-> Compiler (Poly Representation))
+ (-> Lux (Poly Representation))
(p.rec
(function (_ representation)
($_ p.either
@@ -263,7 +263,7 @@
))))
(def: (represent compiler type value)
- (-> Compiler Type Top Text)
+ (-> Lux Type Top Text)
(case (poly.run type (representation compiler))
(#e.Success representation)
(representation value)