wl

Unnamed repository; edit this file 'description' to name the repository.
git clone https://logand.com/git/wl.git/
Log | Files | Refs | LICENSE

commit 2ca9f6ae98d8895cebd078f4440078dd434d6a33
parent 2e90a3297e09e10cc66d6ccf62c772d891aae409
Author: tomas <tomas@logand.com>
Date:   Sun, 18 Oct 2009 00:05:29 +0200

Revert "~ reader"

This reverts commit 2e90a3297e09e10cc66d6ccf62c772d891aae409.

Diffstat:
Mwl.java | 9++-------
1 file changed, 2 insertions(+), 7 deletions(-)

diff --git a/wl.java b/wl.java @@ -189,7 +189,6 @@ class wl implements Runnable { // reader final static Any Lp = mkObj(null); final static Any Rp = mkObj(null); - final static Any Tld = mkObj(null); final Any Qte = mkIsym("quote", NIL); final Any Dot = mkIsym(".", NIL); @@ -297,7 +296,6 @@ class wl implements Runnable { case '"': xchar(); Z = text(); break; case '\'': xchar(); Z = mkCons(Qte, read1(false)); break; case '`': xchar(); Z = eval(read1(false)); break; - case '~': if(Top) Z = symbol(); else {xchar(); Z = Tld;} break; default: Z = symbol(); } } @@ -308,15 +306,12 @@ class wl implements Runnable { Any Z = A; Any X; boolean D = false; - boolean E = false; while(null != (X = read1(false)) && Rp != X) { - if(Dot != X && Tld != X) { - if(E) {X = eval(X); E = false;} + if(Dot != X) { Z.cdr(D ? X : mkCons(X, NIL)); if(Z.cdr().isCons()) Z = Z.cdr(); } - D = Dot == X || Tld == X; - E = Tld == X; + D = Dot == X; } if(null == X) err("Reader underflow"); if(D) Z.cdr(A.cdr());