MCPcopy Create free account
hub / github.com/bytedance/Fastbot_Android / Message

Method Message

native/thirdpart/flatbuffers/idl_parser.cpp:129–143  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

127}
128
129void Parser::Message(const std::string &msg) {
130 if (!error_.empty()) error_ += "\n"; // log all warnings and errors
131 error_ += file_being_parsed_.length() ? AbsolutePath(file_being_parsed_) : "";
132 // clang-format off
133
134 #ifdef _WIN32 // MSVC alike
135 error_ +=
136 "(" + NumToString(line_) + ", " + NumToString(CursorPosition()) + ")";
137 #else // gcc alike
138 if (file_being_parsed_.length()) error_ += ":";
139 error_ += NumToString(line_) + ": " + NumToString(CursorPosition());
140 #endif
141 // clang-format on
142 error_ += ": " + msg;
143}
144
145void Parser::Warning(const std::string &msg) {
146 if (!opts.no_warnings) Message("warning: " + msg);

Callers

nothing calls this directly

Calls 4

AbsolutePathFunction · 0.85
NumToStringFunction · 0.85
emptyMethod · 0.80
lengthMethod · 0.80

Tested by

no test coverage detected