Correctly handle weak undefined symbols. Before we would get a invalid binding
[oota-llvm.git] / test / MC / ELF / weak.s
1 // RUN: llvm-mc -filetype=obj -triple x86_64-pc-linux-gnu %s -o - | elf-dump  | FileCheck %s
2
3 // Test that this produces a weak undefined symbol.
4
5         .weak   foo
6         .long   foo
7
8 //CHECK:       (('st_name', 1) # 'foo'
9 //CHECK-NEXT:   ('st_bind', 2)
10 //CHECK-NEXT:   ('st_type', 0)
11 //CHECK-NEXT:   ('st_other', 0)
12 //CHECK-NEXT:   ('st_shndx', 0)
13 //CHECK-NEXT:   ('st_value', 0)
14 //CHECK-NEXT:   ('st_size', 0)