aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEduardo Julian2018-08-22 22:59:20 -0400
committerEduardo Julian2018-08-22 22:59:20 -0400
commit79c2988c1b514657cc384070e66539e51e105987 (patch)
treed263db7a49d3f847edd0605e1d93f70b340e4541
parentf4f1d14416770cc223676a7d89ed15a11222ef1b (diff)
No more escaping of vertical-tab.
-rw-r--r--luxc/src/lux/lexer.clj2
-rw-r--r--stdlib/source/lux/compiler/default/syntax.lux4
-rw-r--r--stdlib/test/test/lux/compiler/default/syntax.lux2
3 files changed, 2 insertions, 6 deletions
diff --git a/luxc/src/lux/lexer.clj b/luxc/src/lux/lexer.clj
index d52464d5d..02f1e088a 100644
--- a/luxc/src/lux/lexer.clj
+++ b/luxc/src/lux/lexer.clj
@@ -37,8 +37,6 @@
(if (= \\ current-char)
(do (assert (< (+ 1 idx) line-length) (str "[Lexer Error] Text is too short for escaping: " raw-line " " idx))
(case (.charAt raw-line (+ 1 idx))
- \v (do (.append buffer "\u000B")
- (recur (+ 2 idx)))
\n (do (.append buffer "\n")
(recur (+ 2 idx)))
\" (do (.append buffer "\"")
diff --git a/stdlib/source/lux/compiler/default/syntax.lux b/stdlib/source/lux/compiler/default/syntax.lux
index 06672b2aa..89087d482 100644
--- a/stdlib/source/lux/compiler/default/syntax.lux
+++ b/stdlib/source/lux/compiler/default/syntax.lux
@@ -139,7 +139,6 @@
[code l.any]
(case code
## Handle special cases.
- "v" (wrap [2 "\v"])
"n" (wrap [2 ..new-line])
(^ (static ..text-delimiter)) (wrap [2 ..text-delimiter])
(^ (static ..escape)) (wrap [2 ..escape])
@@ -619,8 +618,7 @@
(^template [<input> <output>]
(^ (char <input>))
(!find-next-escape 2 next-escape end source-code total <output>))
- (["v" "\v"]
- ["n" (static ..new-line)]
+ (["n" (static ..new-line)]
[(~~ (static ..escape)) (static ..escape)])
(^ (char (~~ (static ..text-delimiter))))
diff --git a/stdlib/test/test/lux/compiler/default/syntax.lux b/stdlib/test/test/lux/compiler/default/syntax.lux
index 14de95b52..5ac8e16da 100644
--- a/stdlib/test/test/lux/compiler/default/syntax.lux
+++ b/stdlib/test/test/lux/compiler/default/syntax.lux
@@ -30,7 +30,7 @@
(do r.Monad<Random>
[#let [digits "0123456789"
delimiters "()[]{}#.\""
- space "\v \n"
+ space " \n"
invalid-range (format digits delimiters space)
char-gen (|> r.nat
(:: @ map (|>> (n/% 256) (n/max 1)))