MCPcopy Create free account
hub / github.com/beefytech/Beef / UnexpectedCharacter

Method UnexpectedCharacter

IDEHelper/Compiler/BfParser.cpp:540–557  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

538}
539
540void BfParser::UnexpectedCharacter()
541{
542 if (mPreprocessorIgnoredSectionNode != NULL)
543 return;
544
545 int startIdx = mTokenStart;
546 int endIdx = startIdx;
547 char32_t c = u8_nextchar((char*)mSrc, &endIdx);
548 int charLen = endIdx - startIdx;
549
550 String str = "Unexpected character '";
551 for (int i = 0; i < charLen; i++)
552 str += mSrc[startIdx + i];
553 str += StrFormat("' (0x%0X)", (int)c);
554
555 mPassInstance->FailAt(str, mSourceData, startIdx);
556 mSrcIdx = endIdx;
557}
558
559void BfParser::TokenFail(const StringImpl& error, int offset)
560{

Callers

nothing calls this directly

Calls 1

FailAtMethod · 0.80

Tested by

no test coverage detected