| 4144 | } |
| 4145 | |
| 4146 | bool HloParserImpl::ParseToken(TokKind kind, const std::string& msg) { |
| 4147 | VLOG(3) << "ParseToken " << TokKindToString(kind) << " " << msg; |
| 4148 | if (lexer_.GetKind() != kind) { |
| 4149 | return TokenError(msg); |
| 4150 | } |
| 4151 | lexer_.Lex(); |
| 4152 | return true; |
| 4153 | } |
| 4154 | |
| 4155 | bool HloParserImpl::EatIfPresent(TokKind kind) { |
| 4156 | if (lexer_.GetKind() != kind) { |
nothing calls this directly
no test coverage detected