add test for -Clink-self-contained consistency

This commit is contained in:
Rémy Rakic 2023-09-21 13:29:04 +00:00
parent 13948747d0
commit d634cc5a55
3 changed files with 14 additions and 0 deletions

View File

@ -0,0 +1,2 @@
error: some `-C link-self-contained` components were both enabled and disabled: crto, linker

View File

@ -0,0 +1,2 @@
error: some `-C link-self-contained` components were both enabled and disabled: linker

View File

@ -0,0 +1,10 @@
// Checks that self-contained linking components cannot be both enabled and disabled at the same
// time on the CLI.
// check-fail
// revisions: one many
// [one] compile-flags: -Clink-self-contained=-linker -Clink-self-contained=+linker -Zunstable-options
// [many] compile-flags: -Clink-self-contained=+linker,+crto -Clink-self-contained=-linker,-crto -Zunstable-options
// ignore-tidy-linelength
fn main() {}