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

Method LocationToString

IDEHelper/Compiler/BfAst.cpp:867–884  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

865}
866
867String BfAstNode::LocationToString()
868{
869 auto parserData = GetParserData();
870 if (parserData == NULL)
871 return String();
872
873 String loc;
874
875 int line = -1;
876 int lineChar = -1;
877 parserData->GetLineCharAtIdx(mSrcStart, line, lineChar);
878 if (line != -1)
879 loc += StrFormat("at line %d:%d", line + 1, lineChar + 1);
880 loc += " in ";
881 loc += parserData->mFileName;
882
883 return loc;
884}
885
886void BfAstNode::Add(BfAstNode* bfAstNode)
887{

Callers 3

FailMethod · 0.80
HandleCEAttributesMethod · 0.80
ExecuteCEOnCompileMethod · 0.80

Calls 2

StringClass · 0.85
GetLineCharAtIdxMethod · 0.80

Tested by

no test coverage detected