forked from kanaka/mal
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request kanaka#262 from c0deaddict/master
Livescript implementation
- Loading branch information
Showing
26 changed files
with
3,044 additions
and
2 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
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
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,31 @@ | ||
FROM ubuntu:xenial | ||
MAINTAINER Joel Martin <[email protected]> | ||
|
||
########################################################## | ||
# General requirements for testing or common across many | ||
# implementations | ||
########################################################## | ||
|
||
RUN apt-get -y update | ||
|
||
# Required for running tests | ||
RUN apt-get -y install make python | ||
|
||
# Some typical implementation and test requirements | ||
RUN apt-get -y install curl libreadline-dev libedit-dev | ||
|
||
RUN mkdir -p /mal | ||
WORKDIR /mal | ||
|
||
########################################################## | ||
# Specific implementation requirements | ||
########################################################## | ||
|
||
# For building node modules | ||
RUN apt-get -y install g++ | ||
|
||
# Add nodesource apt repo config for 7.X | ||
RUN curl -sL https://deb.nodesource.com/setup_7.x | bash - | ||
|
||
# Install nodejs | ||
RUN apt-get -y install nodejs |
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,40 @@ | ||
SOURCES_BASE = reader.ls printer.ls env.ls core.ls utils.ls | ||
SOURCES_STEPS = step0_repl.ls step1_read_print.ls step2_eval.ls \ | ||
step4_if_fn_do.ls step5_tco.ls step6_file.ls step7_quote.ls \ | ||
step8_macros.ls step9_try.ls stepA_mal.ls | ||
SOURCES_LISP = env.ls core.ls stepA_mal.ls | ||
SOURCES = $(SOURCES_BASE) $(SOURCES_STEPS) | ||
|
||
BINS = $(SOURCES:%.ls=%.js) | ||
|
||
LSC = node_modules/.bin/lsc | ||
|
||
all: node_modules $(BINS) | ||
|
||
node_modules: | ||
npm install | ||
|
||
%.js: %.ls node_modules | ||
$(LSC) -d -c $(@:%.js=%.ls) | ||
|
||
step1_read_print.js: utils.js reader.js printer.js | ||
step2_eval.js: utils.js reader.js printer.js | ||
step3_env.js: utils.js reader.js printer.js env.js | ||
step4_if_fn_do.js: utils.js reader.js printer.js env.js core.js | ||
step5_tco.js: utils.js reader.js printer.js env.js core.js | ||
step6_file.js: utils.js reader.js printer.js env.js core.js | ||
step7_quote.js: utils.js reader.js printer.js env.js core.js | ||
step8_macros.js: utils.js reader.js printer.js env.js core.js | ||
step9_try.js: utils.js reader.js printer.js env.js core.js | ||
stepA_mal.js: utils.js reader.js printer.js env.js core.js | ||
|
||
clean: | ||
rm -f $(BINS) | ||
|
||
stats: $(SOURCES) | ||
@wc $^ | ||
@printf "%5s %5s %5s %s\n" `egrep "^\w*#|^\w*$$" $^ | wc` "[comments/blanks]" | ||
|
||
stats-lisp: $(SOURCES_LISP) | ||
@wc $^ | ||
@printf "%5s %5s %5s %s\n" `egrep "^\w*#|^\w*$$" $^ | wc` "[comments/blanks]" |
Oops, something went wrong.