MCPcopy Create free account
hub / github.com/DaedalusX64/daedalus / SplitAt

Function SplitAt

Source/Utility/StringUtil.cpp:41–58  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

39}
40
41void SplitAt(ConstStringRef str, char split_char, ConstStringRef * left, ConstStringRef * right)
42{
43 for (const char * p = str.Begin; p < str.End; ++p)
44 {
45 if (*p == split_char)
46 {
47 left->Begin = str.Begin;
48 left->End = p;
49 right->Begin = p+1;
50 right->End = str.End;
51 return;
52 }
53 }
54
55 // Split char wasn't found - just return the whole string as 'left'.
56 *left = str;
57 *right = ConstStringRef();
58}
59
60u32 ParseU32(ConstStringRef str, u32 base)
61{

Callers 1

WebDebugConnectionMethod · 0.85

Calls 1

ConstStringRefClass · 0.85

Tested by

no test coverage detected