Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
MistEO committed Dec 26, 2023
1 parent cc113a6 commit ca9f717
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions include/json5.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -143,18 +143,18 @@ class parser5

enum class TokenType
{
punctuator = 0,
eof = 0
punctuator,
identifier,
null,
boolean,
numeric,
string,
eof,
};

struct Token
{
TokenType type;
TokenType type = TokenType::eof;
value _value;
size_t col = 0;
size_t line = 0;
Expand Down Expand Up @@ -823,6 +823,7 @@ inline typename parser5<StringT>::Token parser5<StringT>::lex()
return token.value();
}
}
return Token{ TokenType::eof, value(), _line, _col };
}

template <typename StringT>
Expand Down

0 comments on commit ca9f717

Please sign in to comment.