New testcase for list slicing
authorChris Lattner <sabre@nondot.org>
Tue, 27 Jul 2004 01:00:56 +0000 (01:00 +0000)
committerChris Lattner <sabre@nondot.org>
Tue, 27 Jul 2004 01:00:56 +0000 (01:00 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@15248 91177308-0d34-0410-b5e6-96231b3b80d8

test/TableGen/ListSlices.td [new file with mode: 0644]

diff --git a/test/TableGen/ListSlices.td b/test/TableGen/ListSlices.td
new file mode 100644 (file)
index 0000000..be794cf
--- /dev/null
@@ -0,0 +1,18 @@
+// RUN: tblgen %s
+
+def A {
+  list<int> B = [10, 20, 30, 4, 1, 1231, 20];
+}
+
+def B {
+  list<int> X = [10, 20, 30, 4, 1, 1231, 20] [2-4,2,2,0-6];
+
+  list<int> Y = X[4,5];
+  int Z = X[4];
+
+  list<int> C = A.B[1-4];
+
+  list<list<int>> AA = [X, Y];
+
+  int BB = AA[0][1];
+}