[Piglit] [PATCH] glsl-1.50: test that interface blocks may not be initialized

Matt Turner mattst88 at gmail.com
Wed Jul 24 14:57:55 PDT 2013


---
 .../compiler/interface-blocks-no-initializer.vert  | 23 ++++++++++++++++++++++
 1 file changed, 23 insertions(+)
 create mode 100644 tests/spec/glsl-1.50/compiler/interface-blocks-no-initializer.vert

diff --git a/tests/spec/glsl-1.50/compiler/interface-blocks-no-initializer.vert b/tests/spec/glsl-1.50/compiler/interface-blocks-no-initializer.vert
new file mode 100644
index 0000000..172b7b2
--- /dev/null
+++ b/tests/spec/glsl-1.50/compiler/interface-blocks-no-initializer.vert
@@ -0,0 +1,23 @@
+// [config]
+// expect_result: fail
+// glsl_version: 1.50
+// [end config]
+//
+// GLSLangSpec.1.50.11, 4.3.7 Interface Blocks:
+// "Types and declarators are the same as for other input, output, and uniform
+//  variable declarations outside blocks, with these exceptions:
+//    • initializers are not allowed
+//    • ..."
+//
+// Tests that an interface block name may not initialized.
+
+#version 150
+
+out block {
+    vec4 a;
+} inst = block(vec4(1.0));
+
+void main()
+{
+}
+
-- 
1.8.1.5



More information about the Piglit mailing list