rust/tests/ui/imports/resolve-other-libc.rs
dianne d7d6238b23 use backticks instead of single quotes when reporting "use of unstable library feature"
This is consistent with all other diagnostics I could find containing
features and enables the use of `DiagSymbolList` for generalizing
diagnostics for unstable library features to multiple features.
2024-11-03 13:55:52 -08:00

15 lines
502 B
Rust

// Regression test for https://github.com/rust-lang/rust/issues/26043
//@ compile-flags: --extern libc=test.rlib
// The error shall NOT be something similar to the following, because it
// indicates that `libc` was wrongly resolved to `libc` shipped with the
// compiler:
//
// error[E0658]: use of unstable library feature `rustc_private`: \
// this crate is being loaded from the sysroot
//
extern crate libc; //~ ERROR: extern location for libc does not exist: test.rlib
fn main() {}