summaryrefslogtreecommitdiff
path: root/lld/test/ELF/input-section-flags-diag2.test
blob: a83ab23d7040124b3e0a8595d9fe6a0c14baa157 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
# REQUIRES: x86
# RUN: llvm-mc -filetype=obj -triple=x86_64 /dev/null -o %t.o
# RUN: not ld.lld -shared %t.o -o /dev/null --script %s 2>&1 | FileCheck -strict-whitespace %s

## Check that we start with a flag

SECTIONS {
 .text : { INPUT_SECTION_FLAGS(& SHF_ALLOC) *(.text) }
}

# CHECK:  unrecognised flag: &
# CHECK-NEXT: >>>  .text : { INPUT_SECTION_FLAGS(& SHF_ALLOC) *(.text) }
# CHECK-NEXT: >>>                                ^