[IR/AsmWriter] Output escape sequences if the first character isdigit()
[oota-llvm.git] / test / Assembler / metadata.ll
index 8d5e91fb332fa18a136b7e6c99edbb83654dbdfa..052ac1b5097e04a96b7f642b493a5f83971e7666 100644 (file)
@@ -22,6 +22,13 @@ define void @test3() !bar !3 {
   unreachable, !bar !4
 }
 
+; CHECK-LABEL: define void @test_attachment_name() {
+; CHECK:   unreachable, !\342abc !4
+define void @test_attachment_name() {
+  ;; Escape the first character when printing text IR, since it's a digit
+  unreachable, !\34\32abc !4
+}
+
 !0 = !DILocation(line: 662302, column: 26, scope: !1)
 !1 = !DISubprogram(name: "foo")
 !2 = distinct !{}