projects
/
org.ibex.core.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
local scope vars indexed by number
[org.ibex.core.git]
/
src
/
org
/
ibex
/
js
/
Lexer.java
diff --git
a/src/org/ibex/js/Lexer.java
b/src/org/ibex/js/Lexer.java
index
5aab728
..
42ec2c7
100644
(file)
--- a/
src/org/ibex/js/Lexer.java
+++ b/
src/org/ibex/js/Lexer.java
@@
-43,7
+43,7
@@
class Lexer implements Tokens {
protected String string = null;
/** the line number of the most recently <i>lexed</i> token */
protected String string = null;
/** the line number of the most recently <i>lexed</i> token */
- private int line = 0;
+ protected int line = 0;
/** the line number of the most recently <i>parsed</i> token */
protected int parserLine = 0;
/** the line number of the most recently <i>parsed</i> token */
protected int parserLine = 0;
@@
-137,6
+137,7
@@
class Lexer implements Tokens {
case "implements": return RESERVED;
case "instanceof": return RESERVED;
case "synchronized": return RESERVED;
case "implements": return RESERVED;
case "instanceof": return RESERVED;
case "synchronized": return RESERVED;
+ case "cascade": return CASCADE;
//#end
return -1;
}
//#end
return -1;
}
@@
-194,8
+195,9
@@
class Lexer implements Tokens {
}
}
}
}
- if (!isInteger) this.number = JS.N(dval);
- else this.number = JS.N(longval);
+ if (!isInteger) this.number = new Double(dval);
+ else if(longval >= Integer.MIN_VALUE && longval <= Integer.MAX_VALUE) this.number = new Integer((int)longval);
+ else this.number = new Long(longval);
return NUMBER;
}
return NUMBER;
}