Compare commits
1 Commits
master
...
comment-le
Author | SHA1 | Date | |
---|---|---|---|
|
b325647ad9 |
1
.gitignore
vendored
1
.gitignore
vendored
@ -3,4 +3,3 @@ out/
|
|||||||
*.zip
|
*.zip
|
||||||
prg/**/*.ast
|
prg/**/*.ast
|
||||||
prg/**/*.out
|
prg/**/*.out
|
||||||
prg/**/*.pins25
|
|
2
prg/test.pins25
Normal file
2
prg/test.pins25
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
//1234567890
|
||||||
|
//12345678901
|
@ -246,8 +246,14 @@ public class LexAn implements AutoCloseable {
|
|||||||
buffToken = new Token(start, Token.Symbol.DIV, "/");
|
buffToken = new Token(start, Token.Symbol.DIV, "/");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
nextChar();
|
||||||
|
|
||||||
|
int length = 0;
|
||||||
while (buffChar != '\n' && buffChar != -1) {
|
while (buffChar != '\n' && buffChar != -1) {
|
||||||
|
length++;
|
||||||
|
if (length > 10) {
|
||||||
|
throw new Report.Error(currentLocation(), "Comments can only be 10 characters long");
|
||||||
|
}
|
||||||
nextChar();
|
nextChar();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user