Fix the line number of next in Parser.hpp
Signed-off-by: Username404 <w.iron.zombie@gmail.com>
This commit is contained in:
parent
26d88c2f91
commit
cca696b27a
|
@ -33,7 +33,7 @@ namespace Parser {
|
|||
};
|
||||
for (;i < lexed.size(); ++i) {
|
||||
const bool hasNext = (i + 1) < lexed.size();
|
||||
const tok& current = lexed[i], next = hasNext ? lexed[i + 1] : tok(UNEXPECTED);
|
||||
const tok& current = lexed[i], next = hasNext ? lexed[i + 1] : tok(UNEXPECTED, current.line);
|
||||
|
||||
switch (current.toktype) {
|
||||
case STRING: parseTree << types::String(current.toktext.data()); break;
|
||||
|
|
Loading…
Reference in New Issue