[ELF] Make SyntheticSection parameter order match InputSection
[llvm-project.git] / lld / test / ELF / gc-sections-no-undef-error.s
blobd142998b7f501ace34e55291864c10ca78bcd8e4
1 # REQUIRES: x86
3 # RUN: llvm-mc -filetype=obj -triple=x86_64-pc-linux %s -o %t.o
5 # Sanity check that the link will fail with the undefined error without
6 # gc-sections.
7 # RUN: not ld.lld %t.o -o /dev/null 2>&1 | FileCheck %s
8 # CHECK: error: undefined symbol: undefined
10 # RUN: ld.lld %t.o --gc-sections -o %t
12 .section .text.unused,"ax",@progbits
13 unused:
14 callq undefined
16 .text
17 .global _start
18 _start:
19 nop