MCPcopy Create free account
hub / github.com/WolfireGames/overgrowth / FindStringInArray

Function FindStringInArray

Source/Utility/strings.cpp:100–107  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

98#endif
99
100int FindStringInArray(const char** values, size_t values_size, const char* q) {
101 for (unsigned i = 0; i < values_size; i++) {
102 if (strmtch(values[i], q)) {
103 return i;
104 }
105 }
106 return -1;
107}
108
109int FindStringInArray(const vector<pair<const char*, const char*> >& values, const char* q) {
110 for (unsigned i = 0; i < values.size(); i++) {

Callers 10

SearchXMLMethod · 0.85
SearchLevelRootMethod · 0.85
SearchXMLMethod · 0.85
SearchXMLMethod · 0.85
SearchXMLMethod · 0.85
SearchXMLMethod · 0.85
SearchXMLMethod · 0.85
DoMethod · 0.85
DoMethod · 0.85
DoMethod · 0.85

Calls 2

strmtchFunction · 0.85
sizeMethod · 0.45

Tested by

no test coverage detected