On Wed, Aug 26, 2015 at 2:38 AM, Dave Airlie <[email protected]> wrote:
> From: Dave Airlie <[email protected]>
>
> GL33-CTS.shaders.preprocessor.definitions.*
> has 4 tests the undefine these,
>
> I can't find anything in the spec saying that isn't correct.
>
> Signed-off-by: Dave Airlie <[email protected]>
> ---
> src/glsl/glcpp/glcpp-parse.y | 4 +---
> 1 file changed, 1 insertion(+), 3 deletions(-)
>
> diff --git a/src/glsl/glcpp/glcpp-parse.y b/src/glsl/glcpp/glcpp-parse.y
> index 18e50af..77010b4 100644
> --- a/src/glsl/glcpp/glcpp-parse.y
> +++ b/src/glsl/glcpp/glcpp-parse.y
> @@ -289,9 +289,7 @@ control_line_success:
> } IDENTIFIER NEWLINE {
> macro_t *macro;
> if (strcmp("__LINE__", $4) == 0
> - || strcmp("__FILE__", $4) == 0
> - || strcmp("__VERSION__", $4) == 0
> - || strncmp("GL_", $4, 3) == 0)
From GLSL 4.50 page 12, section 3.3:
All macro
names prefixed with “GL_” (“GL” followed by a single underscore) are
also reserved, and defining such a
name results in a compile-time error. That said I don't see anything
about redefining __FILE__.
> + || strcmp("__FILE__", $4) == 0)
> glcpp_error(& @1, parser, "Built-in (pre-defined)"
> " macro names cannot be undefined.");
>
> --
> 2.4.3
>
> _______________________________________________
> mesa-dev mailing list
> [email protected]
> http://lists.freedesktop.org/mailman/listinfo/mesa-dev
_______________________________________________
mesa-dev mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/mesa-dev