Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit fd1f3ab

Browse filesBrowse files
committed
No need to keep all the IntelliJ Meta Data
1 parent b4c668b commit fd1f3ab
Copy full SHA for fd1f3ab

File tree

Expand file treeCollapse file tree

194 files changed

+373
-3334
lines changed
Filter options

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Dismiss banner
Expand file treeCollapse file tree

194 files changed

+373
-3334
lines changed

‎analysis/Analysis.java

Copy file name to clipboardExpand all lines: analysis/Analysis.java
+1Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -100,4 +100,5 @@ public interface Analysis extends Switch
100100
void caseTWhitespace(TWhitespace node);
101101
void caseTIdentifier(TIdentifier node);
102102
void caseEOF(EOF node);
103+
void caseInvalidToken(InvalidToken node);
103104
}

‎analysis/AnalysisAdapter.java

Copy file name to clipboardExpand all lines: analysis/AnalysisAdapter.java
+6Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -596,6 +596,12 @@ public void caseEOF(EOF node)
596596
defaultCase(node);
597597
}
598598

599+
@Override
600+
public void caseInvalidToken(InvalidToken node)
601+
{
602+
defaultCase(node);
603+
}
604+
599605
public void defaultCase(@SuppressWarnings("unused") Node node)
600606
{
601607
// do nothing

‎lexer/Lexer.java

Copy file name to clipboardExpand all lines: lexer/Lexer.java
+21-2Lines changed: 21 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ public class Lexer
1111
protected Token token;
1212
protected State state = State.INITIAL;
1313

14-
private PushbackReader in;
14+
private IPushbackReader in;
1515
private int line;
1616
private int pos;
1717
private boolean cr;
@@ -24,7 +24,25 @@ protected void filter() throws LexerException, IOException
2424
// Do nothing
2525
}
2626

27-
public Lexer(@SuppressWarnings("hiding") PushbackReader in)
27+
public Lexer(@SuppressWarnings("hiding") final PushbackReader in)
28+
{
29+
this.in = new IPushbackReader() {
30+
31+
private PushbackReader pushbackReader = in;
32+
33+
@Override
34+
public void unread(int c) throws IOException {
35+
pushbackReader.unread(c);
36+
}
37+
38+
@Override
39+
public int read() throws IOException {
40+
return pushbackReader.read();
41+
}
42+
};
43+
}
44+
45+
public Lexer(@SuppressWarnings("hiding") IPushbackReader in)
2846
{
2947
this.in = in;
3048
}
@@ -608,6 +626,7 @@ else if(c > tmp2[1])
608626
if(this.text.length() > 0)
609627
{
610628
throw new LexerException(
629+
new InvalidToken(this.text.substring(0, 1), start_line + 1, start_pos + 1),
611630
"[" + (start_line + 1) + "," + (start_pos + 1) + "]" +
612631
" Unknown token: " + this.text);
613632
}

‎lexer/LexerException.java

Copy file name to clipboardExpand all lines: lexer/LexerException.java
+11-1Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,21 @@
22

33
package lexer;
44

5+
import node.*;
6+
57
@SuppressWarnings("serial")
68
public class LexerException extends Exception
79
{
8-
public LexerException(String message)
10+
private InvalidToken invalidToken;
11+
12+
public LexerException(@SuppressWarnings("hiding") InvalidToken invalidToken, String message)
913
{
1014
super(message);
15+
this.invalidToken = invalidToken;
16+
}
17+
18+
public InvalidToken getToken()
19+
{
20+
return this.invalidToken;
1121
}
1222
}

‎out/production/projekt/.classpath

Copy file name to clipboardExpand all lines: out/production/projekt/.classpath
-6Lines changed: 0 additions & 6 deletions
This file was deleted.

‎out/production/projekt/.idea/.name

Copy file name to clipboardExpand all lines: out/production/projekt/.idea/.name
-1Lines changed: 0 additions & 1 deletion
This file was deleted.

‎out/production/projekt/.idea/ant.xml

Copy file name to clipboardExpand all lines: out/production/projekt/.idea/ant.xml
-7Lines changed: 0 additions & 7 deletions
This file was deleted.

‎out/production/projekt/.idea/compiler.xml

Copy file name to clipboardExpand all lines: out/production/projekt/.idea/compiler.xml
-23Lines changed: 0 additions & 23 deletions
This file was deleted.

‎out/production/projekt/.idea/copyright/profiles_settings.xml

Copy file name to clipboardExpand all lines: out/production/projekt/.idea/copyright/profiles_settings.xml
-5Lines changed: 0 additions & 5 deletions
This file was deleted.

‎out/production/projekt/.idea/encodings.xml

Copy file name to clipboardExpand all lines: out/production/projekt/.idea/encodings.xml
-5Lines changed: 0 additions & 5 deletions
This file was deleted.

‎out/production/projekt/.idea/misc.xml

Copy file name to clipboardExpand all lines: out/production/projekt/.idea/misc.xml
-11Lines changed: 0 additions & 11 deletions
This file was deleted.

‎out/production/projekt/.idea/modules.xml

Copy file name to clipboardExpand all lines: out/production/projekt/.idea/modules.xml
-9Lines changed: 0 additions & 9 deletions
This file was deleted.

‎out/production/projekt/.idea/scopes/scope_settings.xml

Copy file name to clipboardExpand all lines: out/production/projekt/.idea/scopes/scope_settings.xml
-5Lines changed: 0 additions & 5 deletions
This file was deleted.

‎out/production/projekt/.idea/uiDesigner.xml

Copy file name to clipboardExpand all lines: out/production/projekt/.idea/uiDesigner.xml
-125Lines changed: 0 additions & 125 deletions
This file was deleted.

‎out/production/projekt/.idea/vcs.xml

Copy file name to clipboardExpand all lines: out/production/projekt/.idea/vcs.xml
-7Lines changed: 0 additions & 7 deletions
This file was deleted.

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.