[Piglit] [PATCH 4/4] double-underscore-*.frag: Turn these into 1.10 tests.

Ian Romanick idr at freedesktop.org
Fri Oct 7 10:31:26 PDT 2011


On 10/05/2011 12:59 PM, Eric Anholt wrote:
> The requirement hasn't changed at all, so no reason to hide it under 1.30.

The first three in the series are

Reviewed-by: Ian Romanick <ian.d.romanick at intel.com>

This one has a couple of errors.

> ---
>   .../compiler/reserved/double-underscore-01.frag    |   19 +++++++++++++++++++
>   .../compiler/reserved/double-underscore-02.frag    |   19 +++++++++++++++++++
>   .../compiler/reserved/double-underscore-03.frag    |   17 +++++++++++++++++
>   .../compiler/reserved/double-underscore-01.frag    |   18 ------------------
>   .../compiler/reserved/double-underscore-02.frag    |   18 ------------------
>   .../compiler/reserved/double-underscore-03.frag    |   19 -------------------
>   6 files changed, 55 insertions(+), 55 deletions(-)
>   create mode 100644 tests/spec/glsl-1.10/compiler/reserved/double-underscore-01.frag
>   create mode 100644 tests/spec/glsl-1.10/compiler/reserved/double-underscore-02.frag
>   create mode 100644 tests/spec/glsl-1.10/compiler/reserved/double-underscore-03.frag
>   delete mode 100644 tests/spec/glsl-1.30/compiler/reserved/double-underscore-01.frag
>   delete mode 100644 tests/spec/glsl-1.30/compiler/reserved/double-underscore-02.frag
>   delete mode 100644 tests/spec/glsl-1.30/compiler/reserved/double-underscore-03.frag
>
> diff --git a/tests/spec/glsl-1.10/compiler/reserved/double-underscore-01.frag b/tests/spec/glsl-1.10/compiler/reserved/double-underscore-01.frag
> new file mode 100644
> index 0000000..d0028d7
> --- /dev/null
> +++ b/tests/spec/glsl-1.10/compiler/reserved/double-underscore-01.frag
> @@ -0,0 +1,19 @@
> +// [config]
> +// expect_result: fail
> +// glsl_version: 1.10
> +// [end config]
> +//
> +// Check that variable names that contain a double underscore, and the double
> +// underscore is located in the middle of the variable name, are reserved,
> +//
> +// From page 14 (20 of pdf) of the GLSL 1.10 spec:
> +//     "In addition, all identifiers containing two consecutive underscores
> +//     (__) are reserved as possible future keywords."
> +
> +#version 130

I don't think you want this. :)

> +
> +int f()
> +{
> +	int __i_am_reserved;
> +	return 0;
> +}
> diff --git a/tests/spec/glsl-1.10/compiler/reserved/double-underscore-02.frag b/tests/spec/glsl-1.10/compiler/reserved/double-underscore-02.frag
> new file mode 100644
> index 0000000..0198793
> --- /dev/null
> +++ b/tests/spec/glsl-1.10/compiler/reserved/double-underscore-02.frag
> @@ -0,0 +1,19 @@
> +// [config]
> +// expect_result: fail
> +// glsl_version: 1.10
> +// [end config]
> +//
> +// Check that variable names that contain a double underscore, and the double
> +// underscore is located in the middle of the variable name, are reserved,
> +//
> +// From page 14 (20 of pdf) of the GLSL 1.10 spec:
> +//     "In addition, all identifiers containing two consecutive underscores
> +//     (__) are reserved as possible future keywords."
> +
> +#version 130

Or this.

> +
> +int f()
> +{
> +	int i_am_reserved__;
> +	return 0;
> +}
> diff --git a/tests/spec/glsl-1.10/compiler/reserved/double-underscore-03.frag b/tests/spec/glsl-1.10/compiler/reserved/double-underscore-03.frag
> new file mode 100644
> index 0000000..85bb0ce
> --- /dev/null
> +++ b/tests/spec/glsl-1.10/compiler/reserved/double-underscore-03.frag
> @@ -0,0 +1,17 @@
> +// [config]
> +// expect_result: fail
> +// glsl_version: 1.10
> +// [end config]
> +//
> +// Check that variable names that contain a double underscore, and the double
> +// underscore is located in the middle of the variable name, are reserved,
> +//
> +// From page 14 (20 of pdf) of the GLSL 1.10 spec:
> +//     "In addition, all identifiers containing two consecutive underscores
> +//     (__) are reserved as possible future keywords."
> +
> +int f()
> +{
> +	int i__am__reserved;
> +	return 0;
> +}
> diff --git a/tests/spec/glsl-1.30/compiler/reserved/double-underscore-01.frag b/tests/spec/glsl-1.30/compiler/reserved/double-underscore-01.frag
> deleted file mode 100644
> index aa8fa91..0000000
> --- a/tests/spec/glsl-1.30/compiler/reserved/double-underscore-01.frag
> +++ /dev/null
> @@ -1,18 +0,0 @@
> -// [config]
> -// expect_result: fail
> -// glsl_version: 1.30
> -// [end config]
> -//
> -// Check that variable names that begin with a double underscore are reserved.
> -//
> -// From page 16 (22 of pdf) of the GLSL 1.30 spec:
> -//     "In addition, all identifiers containing two consecutive underscores
> -//     (__) are reserved as possible future keywords."
> -
> -#version 130
> -
> -int f()
> -{
> -	int __i_am_reserved;
> -	return 0;
> -}
> diff --git a/tests/spec/glsl-1.30/compiler/reserved/double-underscore-02.frag b/tests/spec/glsl-1.30/compiler/reserved/double-underscore-02.frag
> deleted file mode 100644
> index 75da8e9..0000000
> --- a/tests/spec/glsl-1.30/compiler/reserved/double-underscore-02.frag
> +++ /dev/null
> @@ -1,18 +0,0 @@
> -// [config]
> -// expect_result: fail
> -// glsl_version: 1.30
> -// [end config]
> -//
> -// Check that variable names that end with  a double underscore are reserved.
> -//
> -// From page 16 (22 of pdf) of the GLSL 1.30 spec:
> -//     "In addition, all identifiers containing two consecutive underscores
> -//     (__) are reserved as possible future keywords."
> -
> -#version 130
> -
> -int f()
> -{
> -	int i_am_reserved__;
> -	return 0;
> -}
> diff --git a/tests/spec/glsl-1.30/compiler/reserved/double-underscore-03.frag b/tests/spec/glsl-1.30/compiler/reserved/double-underscore-03.frag
> deleted file mode 100644
> index 77b6d23..0000000
> --- a/tests/spec/glsl-1.30/compiler/reserved/double-underscore-03.frag
> +++ /dev/null
> @@ -1,19 +0,0 @@
> -// [config]
> -// expect_result: fail
> -// glsl_version: 1.30
> -// [end config]
> -//
> -// Check that variable names that contain a double underscore, and the double
> -// underscore is located in the middle of the variable name, are reserved,
> -//
> -// From page 16 (22 of pdf) of the GLSL 1.30 spec:
> -//     "In addition, all identifiers containing two consecutive underscores
> -//     (__) are reserved as possible future keywords."
> -
> -#version 130
> -
> -int f()
> -{
> -	int i__am__reserved;
> -	return 0;
> -}


More information about the Piglit mailing list