Fix parsing of a line with only a # in it.
[oota-llvm.git] / test / MC / AsmParser / line_with_hash.s
diff --git a/test/MC/AsmParser/line_with_hash.s b/test/MC/AsmParser/line_with_hash.s
new file mode 100644 (file)
index 0000000..6fdab40
--- /dev/null
@@ -0,0 +1,15 @@
+# RUN: llvm-mc -triple i386-unknown-unknown %s | FileCheck %s
+
+// We used to incorrectly parse a line with only a # in it
+
+.zero 42
+#
+.ifndef FOO
+.zero 2
+.else
+.endif
+.zero 24
+
+// CHECK: .zero 42
+// CHECK-NEXT: .zero 2
+// CHECK-NEXT: .zero 24