MCPcopy Create free account
hub / github.com/CppCXY/EmmyLuaCodeStyle / IsNumber

Function IsNumber

CodeFormatCore/src/Config/LuaStyle.cpp:7–17  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

5#include <map>
6
7bool IsNumber(std::string_view source) {
8 if (source.empty()) {
9 return false;
10 }
11 for (auto c: source) {
12 if (c > '9' || c < '0') {
13 return false;
14 }
15 }
16 return true;
17}
18
19std::string GetOption(const std::map<std::string, std::string, std::less<>> &configMap, const std::string &key) {
20 auto it = configMap.find(key);

Callers 2

IF_EXISTFunction · 0.85
ParseMethod · 0.85

Calls 1

emptyMethod · 0.45

Tested by

no test coverage detected