Skip to content

test: Add test for hidden symbol that can only be resolved from a DSO#1688

Merged
davidlattimore merged 1 commit intowild-linker:mainfrom
PritamP20:test/hidden-undef
Mar 13, 2026
Merged

test: Add test for hidden symbol that can only be resolved from a DSO#1688
davidlattimore merged 1 commit intowild-linker:mainfrom
PritamP20:test/hidden-undef

Conversation

@PritamP20
Copy link
Contributor

Wild already behaves correctly when a hidden symbol can only be resolved from a shared library (DSO) it errors with an undefined symbol. I confirmed that GNU ld and mold behave the same way. However, Wild didn’t have an integration test for this error case.

This PR adds a new test hidden-undef.c to verify that linking fails when a hidden symbol is declared in the main object but only defined in a shared library.

It also moves hidden-undef.sh from the misc group to ignore in mold_skip_tests.toml, since Wild’s behaviour is correct but the error message format differs from mold’s.

@davidlattimore davidlattimore merged commit 8748a20 into wild-linker:main Mar 13, 2026
22 checks passed
@PritamP20 PritamP20 deleted the test/hidden-undef branch March 13, 2026 12:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants