forked from joxa/joxa
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
split joxa-compiler into several different namespaces
This uses the somewhat new support for mutually recursive namespaces to split the massive joxa-compiler into a bunch of related namespaces. It will take sometime to get these optimially organized but at the very least this makes the compiler itself significantly more approachable. Signed-off-by: Jordan Wilberding <diginux@gmail.com>
- Loading branch information
1 parent
1f7d721
commit 19277c5
Showing
76 changed files
with
84,316 additions
and
78,459 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
## -*- mode: Makefile; fill-column: 75; comment-column: 50; -*- | ||
SRCDIR=$(CURDIR)/src | ||
BEAMDIR=$(CURDIR)/ebin | ||
DEPS_DIR=$(CURDIR)/deps | ||
ERL=$(shell which erl) | ||
EBIN_DIRS=$(wildcard $(DEPS_DIR)/*/ebin) | ||
BASE_ERLCFLAGS=$(EBIN_DIRS:%= -pa %) | ||
ERLCFLAGS=$(BASE_ERLCFLAGS) -pa $(BEAMDIR) | ||
ERLFLAGS=-noshell $(ERLCFLAGS) | ||
|
||
|
||
ASTDIR=$(SRCDIR)/ast | ||
COMP= $(ERL) $(ERLFLAGS) $(TEST_FLAGS) -s 'joxa-compiler' main \ | ||
-extra | ||
|
||
ASTS=$(ASTDIR)/joxa-cmp-util.ast \ | ||
$(ASTDIR)/joxa-cmp-path.ast \ | ||
$(ASTDIR)/joxa-cmp-ctx.ast \ | ||
$(ASTDIR)/joxa-cmp-peg.ast \ | ||
$(ASTDIR)/joxa-cmp-lexer.ast \ | ||
$(ASTDIR)/joxa-cmp-ns.ast \ | ||
$(ASTDIR)/joxa-cmp-call.ast \ | ||
$(ASTDIR)/joxa-cmp-literal.ast \ | ||
$(ASTDIR)/joxa-cmp-binary.ast \ | ||
$(ASTDIR)/joxa-cmp-special-forms.ast \ | ||
$(ASTDIR)/joxa-cmp-case.ast \ | ||
$(ASTDIR)/joxa-cmp-spec.ast \ | ||
$(ASTDIR)/joxa-cmp-expr.ast \ | ||
$(ASTDIR)/joxa-cmp-defs.ast \ | ||
$(ASTDIR)/joxa-cmp-joxa-info.ast \ | ||
$(ASTDIR)/joxa-cmp-checks.ast \ | ||
$(ASTDIR)/joxa-cmp-error-format.ast \ | ||
$(ASTDIR)/joxa-cmp-parser.ast \ | ||
$(ASTDIR)/joxa-compiler.ast | ||
|
||
.PHONY: all | ||
|
||
.PRECIOUS: %/.d | ||
|
||
all: $(ASTS) | ||
|
||
$(ASTDIR)/%.ast: $(SRCDIR)/%.jxa $(BEAMDIR)/jxa_bootstrap.beam | ||
$(ERL) $(ERLFLAGS) -s joxa-compiler main \ | ||
-extra --bootstrap --to_ast -o $(ASTDIR) $< | ||
echo "." >> $@ | ||
$(ERL) $(ERLFLAGS) -s jxa_bootstrap do_bootstrap $(BEAMDIR) $@ -s init stop |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.