diff options
author | Ian Romanick <[email protected]> | 2010-03-23 12:11:50 -0700 |
---|---|---|
committer | Ian Romanick <[email protected]> | 2010-03-23 12:11:50 -0700 |
commit | 7563b50075975a3a6b32de64ecb240398d421a55 (patch) | |
tree | e08cd741631c170ece1a85302b07ad9cf3c8b461 | |
parent | 693bb11b5f817b6a299f03acaf50fc3264c853d0 (diff) |
Add `void' type to table of available types
This will make void-01.glsl test fail, so I may regret this later.
However, this will make supporting functions that return void or
functions that have a void parameter list easier to handle.
-rwxr-xr-x | builtin_types.sh | 3 | ||||
-rw-r--r-- | glsl_types.cpp | 1 |
2 files changed, 4 insertions, 0 deletions
diff --git a/builtin_types.sh b/builtin_types.sh index b7baa59b23c..e09b8309b4a 100755 --- a/builtin_types.sh +++ b/builtin_types.sh @@ -122,6 +122,9 @@ cat <<EOF static const struct glsl_type error_type = glsl_type(GLSL_TYPE_ERROR, 0, 0, ""); +static const struct glsl_type void_type = + glsl_type(GLSL_TYPE_VOID, 0, 0, "void"); + const struct glsl_type *const glsl_error_type = & error_type; EOF diff --git a/glsl_types.cpp b/glsl_types.cpp index 5a087216ea6..af6a40800b0 100644 --- a/glsl_types.cpp +++ b/glsl_types.cpp @@ -50,6 +50,7 @@ generate_110_types(glsl_symbol_table *symtab) Elements(builtin_structure_types)); add_types_to_symbol_table(symtab, builtin_110_deprecated_structure_types, Elements(builtin_110_deprecated_structure_types)); + add_types_to_symbol_table(symtab, & void_type, 1); } |