Switching to JSValue throughout. Implementing operators per base type.

This commit is contained in:
rogerl@netscape.com
1999-05-20 21:16:11 +00:00
parent 95f6a7502d
commit d412a70309
19 changed files with 298 additions and 125 deletions
+11 -1
View File
@@ -7,9 +7,19 @@ class JSString extends JSValue {
void eval(Environment theEnv)
{
theEnv.theStack.push(new StackValue(s));
theEnv.theStack.push(this);
}
void add(Environment theEnv)
{
JSString vR = theEnv.theStack.pop().toJSString();
theEnv.theStack.push(new JSString(s + vR.s));
}
JSString toJSString()
{
return this;
}
String s;