aboutsummaryrefslogtreecommitdiff
path: root/lux-bootstrapper
diff options
context:
space:
mode:
authorEduardo Julian2021-07-11 01:51:04 -0400
committerEduardo Julian2021-07-11 01:51:04 -0400
commitabe24425ced15fd784ef6c62d6f186af72b491db (patch)
tree42b6e3cbd179c83fae8941fa4b128b13afc766f5 /lux-bootstrapper
parent4610968193df10af12c91f699fec39aeb3ef703a (diff)
Re-named ":coerce" to ":as" since it technically doesn't do coercions.
Diffstat (limited to 'lux-bootstrapper')
-rw-r--r--lux-bootstrapper/code_of_conduct.md22
-rw-r--r--lux-bootstrapper/commands.md17
-rw-r--r--lux-bootstrapper/src/lux/analyser.clj10
-rw-r--r--lux-bootstrapper/src/lux/analyser/lux.clj4
4 files changed, 24 insertions, 29 deletions
diff --git a/lux-bootstrapper/code_of_conduct.md b/lux-bootstrapper/code_of_conduct.md
deleted file mode 100644
index 01b8644f1..000000000
--- a/lux-bootstrapper/code_of_conduct.md
+++ /dev/null
@@ -1,22 +0,0 @@
-# Contributor Code of Conduct
-
-As contributors and maintainers of this project, and in the interest of fostering an open and welcoming community, we pledge to respect all people who contribute through reporting issues, posting feature requests, updating documentation, submitting pull requests or patches, and other activities.
-
-We are committed to making participation in this project a harassment-free experience for everyone, regardless of level of experience, gender, gender identity and expression, sexual orientation, disability, personal appearance, body size, race, ethnicity, age, religion, or nationality.
-
-Examples of unacceptable behavior by participants include:
-
-* The use of sexualized language or imagery
-* Personal attacks
-* Trolling or insulting/derogatory comments
-* Public or private harassment
-* Publishing other's private information, such as physical or electronic addresses, without explicit permission
-* Other unethical or unprofessional conduct.
-
-Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct. By adopting this Code of Conduct, project maintainers commit themselves to fairly and consistently applying these principles to every aspect of managing this project. Project maintainers who do not follow or enforce the Code of Conduct may be permanently removed from the project team.
-
-This code of conduct applies both within project spaces and in public spaces when an individual is representing the project or its community.
-
-Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by opening an issue or contacting one or more of the project maintainers.
-
-This Code of Conduct is adapted from the [Contributor Covenant](http://contributor-covenant.org), version 1.2.0, available at [http://contributor-covenant.org/version/1/2/0/](http://contributor-covenant.org/version/1/2/0/)
diff --git a/lux-bootstrapper/commands.md b/lux-bootstrapper/commands.md
new file mode 100644
index 000000000..33fa874ba
--- /dev/null
+++ b/lux-bootstrapper/commands.md
@@ -0,0 +1,17 @@
+# Old/bootstrapping compiler
+
+## Build & install
+
+```
+cd ~/lux/lux-bootstrapper/ \
+&& lein clean \
+&& lein install
+```
+
+## Run JBE (Read generated bytecode)
+
+```
+cd ~/lux/jbe/bin/ \
+&& java ee.ioc.cs.jbe.browser.BrowserApplication
+```
+
diff --git a/lux-bootstrapper/src/lux/analyser.clj b/lux-bootstrapper/src/lux/analyser.clj
index af272fa91..792006ed1 100644
--- a/lux-bootstrapper/src/lux/analyser.clj
+++ b/lux-bootstrapper/src/lux/analyser.clj
@@ -109,23 +109,23 @@
(|case command
(&/$Text ?procedure)
(case ?procedure
- "lux check"
+ "lux type check"
(|let [(&/$Cons ?type
(&/$Cons ?value
(&/$Nil))) parameters]
(&/with-analysis-meta location exo-type
- (&&lux/analyse-ann analyse eval! exo-type ?type ?value)))
+ (&&lux/analyse-type-check analyse eval! exo-type ?type ?value)))
- "lux check type"
+ "lux type check type"
(|let [(&/$Cons ?value (&/$Nil)) parameters]
(analyse-ast optimize eval! compile-module compilers &type/Type ?value))
- "lux coerce"
+ "lux type as"
(|let [(&/$Cons ?type
(&/$Cons ?value
(&/$Nil))) parameters]
(&/with-analysis-meta location exo-type
- (&&lux/analyse-coerce analyse eval! exo-type ?type ?value)))
+ (&&lux/analyse-type-as analyse eval! exo-type ?type ?value)))
"lux def"
(|let [(&/$Cons [_ (&/$Identifier "" ?name)]
diff --git a/lux-bootstrapper/src/lux/analyser/lux.clj b/lux-bootstrapper/src/lux/analyser/lux.clj
index 63bc675de..b3c2edbd9 100644
--- a/lux-bootstrapper/src/lux/analyser/lux.clj
+++ b/lux-bootstrapper/src/lux/analyser/lux.clj
@@ -703,7 +703,7 @@
(&&/|meta new-type _location
_analysis)))
-(defn analyse-ann [analyse eval! exo-type ?type ?value]
+(defn analyse-type-check [analyse eval! exo-type ?type ?value]
(|do [=type (&&/analyse-1 analyse &type/Type ?type)
==type (eval! =type)
_ (&type/check exo-type ==type)
@@ -713,7 +713,7 @@
(&&/$ann =value =type)
)))))
-(defn analyse-coerce [analyse eval! exo-type ?type ?value]
+(defn analyse-type-as [analyse eval! exo-type ?type ?value]
(|do [=type (&&/analyse-1 analyse &type/Type ?type)
==type (eval! =type)
_ (&type/check exo-type ==type)