fixed bug 465
[org.ibex.core.git] / src / org / ibex / js / Lexer.java
index 6e77eb7..ac6f6e1 100644 (file)
@@ -24,7 +24,7 @@ import java.io.*;
 class Lexer implements Tokens {
 
     /** for debugging */
-    public static void main(String[] s) throws Exception {
+    public static void main(String[] s) throws IOException {
         Lexer l = new Lexer(new InputStreamReader(System.in), "stdin", 0);
         int tok = 0;
         while((tok = l.getToken()) != -1) System.out.println(codeToString[tok]);
@@ -43,7 +43,7 @@ class Lexer implements Tokens {
     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;
@@ -202,7 +202,6 @@ class Lexer implements Tokens {
     private int getString(int c) throws IOException {
         StringBuffer stringBuf = null;
         int quoteChar = c;
-        int val = 0;
         c = in.read();
         in.startString(); // start after the first "
         while(c != quoteChar) {