MCPcopy Create free account
hub / github.com/Kitware/CMake / decode_bad

Function decode_bad

Tests/CMakeLib/testUTF8.cxx:104–116  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

102}
103
104static bool decode_bad(test_utf8_char s)
105{
106 unsigned int uc = 0xFFFFu;
107 char const* e = cm_utf8_decode_character(s.data(), s.data() + s.size(), &uc);
108 if (e) {
109 report_bad(false, s);
110 printf("expected failure, got 0x%04X\n", uc);
111 return false;
112 }
113 report_bad(true, s);
114 printf("failed as expected\n");
115 return true;
116}
117
118static void report_valid(bool passed, test_utf8_char s)
119{

Callers 1

testUTF8Function · 0.85

Calls 4

cm_utf8_decode_characterFunction · 0.85
report_badFunction · 0.85
dataMethod · 0.45
sizeMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…