aboutsummaryrefslogtreecommitdiff
path: root/lux-bootstrapper/src
diff options
context:
space:
mode:
Diffstat (limited to 'lux-bootstrapper/src')
-rw-r--r--lux-bootstrapper/src/lux/analyser/lux.clj6
-rw-r--r--lux-bootstrapper/src/lux/base.clj8
2 files changed, 7 insertions, 7 deletions
diff --git a/lux-bootstrapper/src/lux/analyser/lux.clj b/lux-bootstrapper/src/lux/analyser/lux.clj
index 6f7b747c1..23f6cf4fa 100644
--- a/lux-bootstrapper/src/lux/analyser/lux.clj
+++ b/lux-bootstrapper/src/lux/analyser/lux.clj
@@ -578,7 +578,7 @@
(eval! (optimize analysis))))
(defn analyse-def* [analyse optimize eval! compile-def ?name ?value exported? type? & [?expected-type]]
- (|do [_ &/ensure-directive
+ (|do [_ &/ensure-declaration
module-name &/get-module-name
_ (ensure-undefined! module-name ?name)
=value (&/without-repl-closure
@@ -684,7 +684,7 @@
(deliver (&/$Right _compiler))))))))
(defn analyse-module [analyse optimize eval! compile-module ?imports]
- (|do [_ &/ensure-directive
+ (|do [_ &/ensure-declaration
module-name &/get-module-name
_imports (&&module/fetch-imports ?imports)
current-module &/get-module-name
@@ -741,7 +741,7 @@
(let [program-type (&/$Function (&/$Apply &type/Text &type/List)
(&/$Apply &type/Any &type/IO))]
(defn analyse-program [analyse optimize compile-program ?program]
- (|do [_ &/ensure-directive
+ (|do [_ &/ensure-declaration
=program (&&/analyse-1 analyse program-type ?program)
_ (compile-program (optimize =program))]
(return &/$End))))
diff --git a/lux-bootstrapper/src/lux/base.clj b/lux-bootstrapper/src/lux/base.clj
index 88f06d928..d0c457680 100644
--- a/lux-bootstrapper/src/lux/base.clj
+++ b/lux-bootstrapper/src/lux/base.clj
@@ -478,7 +478,7 @@
($Item head tail))
($Item (T [slot value]) $End)
prefix)
-
+
($Item [k v] input*)
(if (= k slot)
(fold (fn [tail head]
@@ -487,7 +487,7 @@
prefix)
(recur ($Item (T [k v]) prefix)
input*))
- )))
+ )))
(defmacro |table [& elems]
(reduce (fn [table [k v]]
@@ -1115,14 +1115,14 @@
output))))))
(def ^{:doc "(Meta Any)"}
- ensure-directive
+ ensure-declaration
(fn [state]
(|case (get$ $expected state)
($None)
(return* state unit-tag)
($Some _)
- ((fail-with-loc "[Error] All directives must be top-level forms.")
+ ((fail-with-loc "[Error] All declarations must be top-level forms.")
state))))
(def location