|
OpenEnroth 0259030
|
Functions | |
| Blob | preprocess (const Blob &source, const FileSystem *pwd, std::string_view preamble, std::span< const std::string_view > passthroughDirectives) |
| Blob pp::preprocess | ( | const Blob & | source, |
| const FileSystem * | pwd, | ||
| std::string_view | preamble = {}, |
||
| std::span< const std::string_view > | passthroughDirectives = {} |
||
| ) |
Preprocesses source code, handling #include and #define directives.
| source | The source code to preprocess. |
| pwd | FileSystem for resolving includes (relative to its root). |
| preamble | Optional preamble prepended before preprocessing (e.g., #define GL_ES\n). |
| passthroughDirectives | Directives that should pass through unchanged (e.g., {"version", "extension"}). |
Blob. | Exception | On preprocessing errors. |