Name |
Date |
Size |
#Lines |
LOC |
||
---|---|---|---|---|---|---|
.. | - | - | ||||
tests/ | 03-May-2024 | - | 3,040 | 1,607 | ||
README | D | 03-May-2024 | 1 KiB | 30 | 22 | |
glcpp-lex.l | D | 03-May-2024 | 16.4 KiB | 622 | 364 | |
glcpp-parse.y | D | 03-May-2024 | 72 KiB | 2,550 | 1,843 | |
glcpp.c | D | 03-May-2024 | 4.3 KiB | 183 | 127 | |
glcpp.h | D | 03-May-2024 | 6.5 KiB | 278 | 193 | |
meson.build | D | 03-May-2024 | 4 KiB | 110 | 98 | |
pp.c | D | 03-May-2024 | 7.1 KiB | 257 | 149 | |
pp_standalone_scaffolding.c | D | 03-May-2024 | 1.8 KiB | 58 | 23 | |
pp_standalone_scaffolding.h | D | 03-May-2024 | 1.8 KiB | 48 | 13 |
README
1glcpp -- GLSL "C" preprocessor 2 3This is a simple preprocessor designed to provide the preprocessing 4needs of the GLSL language. The requirements for this preprocessor are 5specified in the GLSL 1.30 specification availble from: 6 7http://www.opengl.org/registry/doc/GLSLangSpec.Full.1.30.10.pdf 8 9This specification is not precise on some semantics, (for example, 10#define and #if), defining these merely "as is standard for C++ 11preprocessors". To fill in these details, I've been using a draft of 12the C99 standard as available from: 13 14http://www.open-std.org/jtc1/sc22/wg14/www/docs/n1256.pdf 15 16Any downstream compiler accepting output from glcpp should be prepared 17to encounter and deal with the following preprocessor macros: 18 19 #line 20 #pragma 21 #extension 22 23All other macros will be handled according to the GLSL specification 24and will not appear in the output. 25 26Known limitations 27----------------- 28A file that ends with a function-like macro name as the last 29non-whitespace token will result in a parse error, (where it should be 30passed through as is).