| 281 | #define checkCodeInternal(...) checkCodeInternal_(__FILE__, __LINE__, __VA_ARGS__) |
| 282 | template<size_t size> |
| 283 | std::string checkCodeInternal_(const char* file, int line, const char (&code)[size], bool cpp) { |
| 284 | // tokenize.. |
| 285 | SimpleTokenizer tokenizer(settings, *this, cpp); |
| 286 | ASSERT_LOC(tokenizer.tokenize(code), file, line); |
| 287 | |
| 288 | // call all "runChecks" in all registered Check classes |
| 289 | for (Check * const c : CheckInstances::get()) { |
| 290 | c->runChecks(tokenizer, *this); |
| 291 | } |
| 292 | |
| 293 | return tokenizer.tokens()->stringifyList(false, false, false, true, false, nullptr, nullptr); |
| 294 | } |
| 295 | |
| 296 | template<size_t size> |
| 297 | std::string checkCode(const char (&code)[size], bool cpp = true) { |
nothing calls this directly
no test coverage detected