aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEduardo Julian2015-01-19 01:45:02 -0400
committerEduardo Julian2015-01-19 01:45:02 -0400
commita14d86d958af652f7bc4ce669dffcc100d2a084c (patch)
tree1fa81db7a1d478ee2f1c72b107970250b0c8df0d
parenta1d619ac4679f246a92ee5e557ed1341f5629221 (diff)
[Enhancements]
Source code is looked-up inside a "source" directory.
Diffstat (limited to '')
-rw-r--r--source/another.lux (renamed from another.lux)0
-rw-r--r--source/test2.lux (renamed from test2.lux)0
-rw-r--r--src/lux.clj2
-rw-r--r--src/lux/compiler.clj2
4 files changed, 2 insertions, 2 deletions
diff --git a/another.lux b/source/another.lux
index ff5bb6f0a..ff5bb6f0a 100644
--- a/another.lux
+++ b/source/another.lux
diff --git a/test2.lux b/source/test2.lux
index d036bbde4..d036bbde4 100644
--- a/test2.lux
+++ b/source/test2.lux
diff --git a/src/lux.clj b/src/lux.clj
index f21a336e0..6efbcc207 100644
--- a/src/lux.clj
+++ b/src/lux.clj
@@ -24,7 +24,7 @@
;; TODO: Reinplement "if" as a macro on top of case.
;; TODO:
- (let [source-code (slurp "test2.lux")
+ (let [source-code (slurp "source/test2.lux")
tokens (&lexer/lex source-code)
;; _ (prn 'tokens tokens)
syntax (&parser/parse tokens)
diff --git a/src/lux/compiler.clj b/src/lux/compiler.clj
index 2a347aa46..5b901c08e 100644
--- a/src/lux/compiler.clj
+++ b/src/lux/compiler.clj
@@ -1105,7 +1105,7 @@
[::&analyser/use ?file ?alias]
(let [module-name (re-find #"[^/]+$" ?file)
;; _ (prn 'module-name module-name)
- source-code (slurp (str module-name ".lux"))
+ source-code (slurp (str "source/" module-name ".lux"))
;; _ (prn 'source-code source-code)
tokens (&lexer/lex source-code)
;; _ (prn 'tokens tokens)