[Piglit] [PATCH 04/23] arb_shading_language_420pack: Test too many elements in array initializer

Matt Turner mattst88 at gmail.com
Sat Jun 29 19:42:57 PDT 2013


---
 ...gal-aggregate-initializer-array-too-many-elements.frag | 15 +++++++++++++++
 1 file changed, 15 insertions(+)
 create mode 100644 tests/spec/arb_shading_language_420pack/compiler/illegal-aggregate-initializer-array-too-many-elements.frag

diff --git a/tests/spec/arb_shading_language_420pack/compiler/illegal-aggregate-initializer-array-too-many-elements.frag b/tests/spec/arb_shading_language_420pack/compiler/illegal-aggregate-initializer-array-too-many-elements.frag
new file mode 100644
index 0000000..9854a10
--- /dev/null
+++ b/tests/spec/arb_shading_language_420pack/compiler/illegal-aggregate-initializer-array-too-many-elements.frag
@@ -0,0 +1,15 @@
+/* [config]
+ * expect_result: fail
+ * glsl_version: 1.30
+ * require_extensions: GL_ARB_shading_language_420pack
+ * [end config]
+ */
+
+#version 130
+#extension GL_ARB_shading_language_420pack: enable
+
+void main() {
+    // Illegal since a has only 2 elements, but 3 elements given as initializer
+    float a[2] = { 3.4, 4.2, 5.0 };
+    gl_FragColor = vec4(1.0);
+}
-- 
1.8.1.5



More information about the Piglit mailing list