preprocessor: Undefining __VERSION__ on GLSL 3.30 is not an error
authorEduardo Lima Mitev <elima@igalia.com>
Wed, 8 Mar 2017 08:42:25 +0000 (09:42 +0100)
committerAlexander Galazin <Alexander.Galazin@arm.com>
Fri, 10 Mar 2017 17:01:38 +0000 (12:01 -0500)
commit7a191949aee68a26bc3f1140dd5dbc2cda4140b5
tree9077831917c5b0c4870ea082d1481b9624d92d4f
parenta1cdc3c68a00b114597e65b1c89cd330db9b252e
preprocessor: Undefining __VERSION__ on GLSL 3.30 is not an error

OpenGL Shading Language 4.5 spec, section '3.3 Preprocessor',
page 12 states:

   "By convention, all macro names containing two consecutive
    underscores ( __ ) are reserved for use by underlying
    software layers. Defining such a name in a shader does not
    itself result in an error, but may result in unintended
    behaviors that stem from having multiple definitions of the
    same name."

There is no explicit mention to #undef, but the consensus is that
defining or undefining are both subject to the same restrictions
in this context.

Affects:
GL45-CTS.shaders.preprocessor.definitions.undefine_version_fragment
GL45-CTS.shaders.preprocessor.definitions.undefine_version_vertex

VK-GL-CTS issue: 206

Components: OpenGL

Change-Id: I36c9ada736d7704767e403b18f21d7343dff1aa2
external/openglcts/data/gl33/preprocessor.test