Fix tests

This commit is contained in:
Antoni Boucher 2023-06-11 19:27:39 -04:00
parent 3371fce044
commit ef037e6d30
4 changed files with 6 additions and 1 deletions

View File

@ -9,6 +9,7 @@ compiler_builtins = "0.1"
alloc = { path = "./sysroot_src/library/alloc" }
std = { path = "./sysroot_src/library/std", features = ["panic_unwind", "backtrace"] }
test = { path = "./sysroot_src/library/test" }
proc_macro = { path = "./sysroot_src/library/proc_macro" }
[patch.crates-io]
rustc-std-workspace-core = { path = "./sysroot_src/library/rustc-std-workspace-core" }

View File

@ -66,3 +66,5 @@ tests/ui/generator/panic-safe.rs
tests/ui/issues/issue-14875.rs
tests/ui/issues/issue-29948.rs
tests/ui/panic-while-printing.rs
tests/ui/enum-discriminant/get_discr.rs
tests/ui/panics/nested_panic_caught.rs

View File

@ -132,7 +132,7 @@ fn declare_raw_fn<'gcc>(cx: &CodegenCx<'gcc, '_>, name: &str, _callconv: () /*ll
pub fn mangle_name(name: &str) -> String {
name.replace(|char: char| {
if !char.is_alphanumeric() && char != '_' {
debug_assert!("$.".contains(char), "Unsupported char in function name: {}", char);
debug_assert!("$.*".contains(char), "Unsupported char in function name {}: {}", name, char);
true
}
else {

View File

@ -350,6 +350,8 @@ function test_rustc() {
for test in $(rg -i --files-with-matches "//(\[\w+\])?~|// error-pattern:|// build-fail|// run-fail|-Cllvm-args" tests/ui); do
rm $test
done
rm tests/ui/consts/const_cmp_type_id.rs
rm tests/ui/consts/issue-73976-monomorphic.rs
git checkout -- tests/ui/issues/auxiliary/issue-3136-a.rs # contains //~ERROR, but shouldn't be removed