MCPcopy Create free account
hub / github.com/BYVoid/OpenCC / ParseInt32Flag

Function ParseInt32Flag

deps/google-benchmark/src/commandlineflags.cc:222–233  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

220}
221
222BENCHMARK_EXPORT
223bool ParseInt32Flag(const char* str, const char* flag, int32_t* value) {
224 // Gets the value of the flag as a string.
225 const char* const value_str = ParseFlagValue(str, flag, false);
226
227 // Aborts if the parsing failed.
228 if (value_str == nullptr) return false;
229
230 // Sets *value to the value of the flag.
231 return ParseInt32(std::string("The value of flag --") + flag, value_str,
232 value);
233}
234
235BENCHMARK_EXPORT
236bool ParseDoubleFlag(const char* str, const char* flag, double* value) {

Callers 1

ParseCommandLineFlagsFunction · 0.85

Calls 2

ParseFlagValueFunction · 0.70
ParseInt32Function · 0.70

Tested by

no test coverage detected