| 158 | } |
| 159 | |
| 160 | static std::string ExtractIncludeFile(const std::string& source) { |
| 161 | std::string file; |
| 162 | bool foundQuote = false; |
| 163 | for (size_t i = 0; i < source.size(); ++i) { |
| 164 | const char c = source[i]; |
| 165 | if (c == '\"') { |
| 166 | if (foundQuote) { |
| 167 | break; |
| 168 | } |
| 169 | foundQuote = true; |
| 170 | } |
| 171 | else if (foundQuote) { |
| 172 | file += c; |
| 173 | } |
| 174 | } |
| 175 | |
| 176 | return file; |
| 177 | } |
| 178 | |
| 179 | static void PreprocessIncludes(std::string& source, const std::filesystem::path& root, const std::unordered_set<std::string>& allShaders) { |
| 180 | std::unordered_set<std::string> seenIncludes; |
no outgoing calls
no test coverage detected