llvm/clang/test/Preprocessor/print-assembler.s
Reid Kleckner 400a64e81b Don't print end-of-directive tokens in -E output
This comes up when pre-processing standalone .s files containing
hash-prefixed comments. The pre-processor should skip the unknown
directive and not emit an extra newline as we were doing.

Fixes PR34950

llvm-svn: 315953
2017-10-16 23:07:15 +00:00

17 lines
304 B
ArmAsm

// RUN: %clang_cc1 -E -x assembler-with-cpp %s -o - | FileCheck %s --strict-whitespace
.intel_syntax noprefix
.text
.global _main
_main:
# asdf
# asdf
mov bogus_name, 20
mov rax, 5
ret
// CHECK-LABEL: _main:
// CHECK-NEXT: {{^}} # asdf
// CHECK-NEXT: {{^}} # asdf
// CHECK-NEXT: mov bogus_name, 20