diff options
Diffstat (limited to 'test/ELF/linkerscript/assert.s')
-rw-r--r-- | test/ELF/linkerscript/assert.s | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/test/ELF/linkerscript/assert.s b/test/ELF/linkerscript/assert.s index 73cc940669b9..f7113e5b25f0 100644 --- a/test/ELF/linkerscript/assert.s +++ b/test/ELF/linkerscript/assert.s @@ -6,7 +6,7 @@ # RUN: llvm-readobj %t1 > /dev/null # RUN: echo "SECTIONS { ASSERT(0, fail) }" > %t3.script -# RUN: not ld.lld -shared -o %t3 --script %t3.script %t1.o > %t.log 2>&1 +# RUN: not ld.lld -shared -o /dev/null --script %t3.script %t1.o > %t.log 2>&1 # RUN: FileCheck %s -check-prefix=FAIL < %t.log # FAIL: fail @@ -30,10 +30,11 @@ # RUN: ld.lld -shared -o %t6 --script %t6.script %t1.o # RUN: llvm-readobj %t6 > /dev/null +## Unlike the GNU ld, we accept the ASSERT without the semicolon. +## It is consistent with how ASSERT can be written outside of the +## output section declaration. # RUN: echo "SECTIONS { .foo : { ASSERT(1, \"true\") } }" > %t7.script -# RUN: not ld.lld -shared -o %t7 --script %t7.script %t1.o > %t.log 2>&1 -# RUN: FileCheck %s -check-prefix=CHECK-SEMI < %t.log -# CHECK-SEMI: error: {{.*}}.script:1: ; expected, but got } +# RUN: ld.lld -shared -o /dev/null --script %t7.script %t1.o .section .foo, "a" .quad 0 |