Skip to content

Commit

Permalink
Revived the lisp test.
Browse files Browse the repository at this point in the history
All hail the lisp test!

Closes SI-4579.
  • Loading branch information
paulp committed Mar 28, 2012
1 parent 3e40fb5 commit 97f0324
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
1 change: 0 additions & 1 deletion test/disabled/run/lisp.check → test/files/run/lisp.check
Expand Up @@ -23,4 +23,3 @@ List('lambda, List('x), List('+, List('*, 'x, 'x), 1))
faculty(10) = 3628800
faculty(10) = 3628800
foobar = ("a" "bc" "def" "z")

6 changes: 3 additions & 3 deletions test/disabled/run/lisp.scala → test/files/run/lisp.scala
Expand Up @@ -12,11 +12,11 @@ class LispTokenizer(s: String) extends Iterator[String] {
while (i < s.length() && s.charAt(i) <= ' ') i += 1
i < s.length()
}
def next: String =
def next: String =
if (hasNext) {
val start = i
if (isDelimiter(s charAt i)) i += 1
else
else
do i = i + 1
while (!isDelimiter(s charAt i))
s.substring(start, i)
Expand Down Expand Up @@ -312,7 +312,7 @@ object LispAny extends Lisp {
case 'cond :: ('else :: expr :: Nil) :: rest =>
normalize(expr);
case 'cond :: (test :: expr :: Nil) :: rest =>
normalize('if :: test :: expr :: ('cond :: rest) :: Nil)
normalize('if :: test :: expr :: ('cond :: rest) :: Nil)
case 'cond :: 'else :: expr :: Nil =>
normalize(expr)
case h :: t =>
Expand Down

0 comments on commit 97f0324

Please sign in to comment.