New testcase
authorChris Lattner <sabre@nondot.org>
Sun, 3 Aug 2003 18:28:09 +0000 (18:28 +0000)
committerChris Lattner <sabre@nondot.org>
Sun, 3 Aug 2003 18:28:09 +0000 (18:28 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@7525 91177308-0d34-0410-b5e6-96231b3b80d8

test/TableGen/BitsInitOverflow.td [new file with mode: 0644]
test/TableGen/IntBitInit.td [new file with mode: 0644]
test/TableGen/ListConversion.td [new file with mode: 0644]

diff --git a/test/TableGen/BitsInitOverflow.td b/test/TableGen/BitsInitOverflow.td
new file mode 100644 (file)
index 0000000..c0b5da9
--- /dev/null
@@ -0,0 +1,5 @@
+// RUN: not tblgen %s
+
+def {
+  bits<2> X = 5;  // bitfield is too small, reject
+}
diff --git a/test/TableGen/IntBitInit.td b/test/TableGen/IntBitInit.td
new file mode 100644 (file)
index 0000000..b949bfe
--- /dev/null
@@ -0,0 +1,5 @@
+// RUN: tblgen %s
+def {
+  bit A = 1;
+  int B = A;
+}
diff --git a/test/TableGen/ListConversion.td b/test/TableGen/ListConversion.td
new file mode 100644 (file)
index 0000000..773ed6e
--- /dev/null
@@ -0,0 +1,10 @@
+// RUN: tblgen %s
+class A;
+class B : A;
+
+def b : B;
+
+def {
+  list<B> X = [b];
+  list<A> Y = X;
+}