llvm-project/lld/test/core/undef-fallback.objtxt

38 lines
786 B
Plaintext

# RUN: lld -core %s | FileCheck %s
# Test that fallback atoms can be parsed by YAML reader and processed by the
# core linker.
---
defined-atoms:
- name: def1
scope: global
undefined-atoms:
- name: undef1
fallback:
name: fallback1
- name: undef2
fallback:
name: fallback2
---
defined-atoms:
- name: fallback1
undefined-atoms:
- name: def1
fallback:
name: fallback3
...
# CHECK: defined-atoms:
# CHECK-NEXT: - name: def1
# CHECK-NEXT: scope: global
# CHECK-NEXT: - name: fallback1
# CHECK-NEXT: ref-name: fallback1
# CHECK-NEXT: undefined-atoms:
# CHECK-NEXT: - name: fallback1
# CHECK-NEXT: - name: fallback2
# CHECK-NOT: - name: fallback3