os-rust/tests
Matthias Krüger 9abf8b105e
Rollup merge of #125622 - oli-obk:define_opaque_types15, r=compiler-errors
Winnow private method candidates instead of assuming any candidate of the right name will apply

partially reverts https://github.com/rust-lang/rust/pull/60721

My original motivation was just to avoid the `delay_span_bug` (by attempting to thread the `ErrorGuaranteed` through to here). But then I realized that the error message is wrong. It refers to the `Foo<A>::foo` instead of `Foo<B>::foo`. This is almost invisible, because both functions are the same, but on different lines, so `-Zui-testing` makes it so the test is the same no matter which of these two functions is referenced.

But there's a much more obvious bug: If `Foo<B>` does not have a `foo` method at all, but `Foo<A>` has a private `foo` method, then we'll refer to that one. This has now been fixed, and we report a normal `method not found` error.

The way this is done is by creating a list of all possible private functions (just like we create a list of the public functions that can actually be called), and then winnowing it by analyzing where bounds and `Self` types to see if any of the found methods can actually apply (again, just like with the list of public functions).

I wonder if there is room for doing the same thing with unstable functions instead of running all of method resolution twice.

r? ``@compiler-errors`` for method resolution stuff
2024-06-05 18:21:11 +02:00
..
assembly Run rustfmt on tests/assembly/. 2024-05-30 16:15:46 +10:00
auxiliary Clean up users of rust_dbg_call 2024-04-17 15:08:08 -04:00
codegen Test codegen for repr(packed,simd) -> repr(simd) 2024-06-02 20:15:15 -07:00
codegen-units Run rustfmt on tests/codegen-units/. 2024-05-31 15:56:45 +10:00
coverage coverage: Instrument the RHS value of lazy logical operators 2024-05-30 15:38:46 +10:00
coverage-run-rustdoc
crashes Rollup merge of #124840 - bvanjoi:fix-124490, r=petrochenkov 2024-06-05 18:21:11 +02:00
debuginfo Increase vtable layout size 2024-06-01 07:42:05 -04:00
incremental Update tests/incremental/foreign.rs 2024-05-20 11:13:10 -04:00
mir-opt rustfmt tests/mir-opt. 2024-06-03 14:17:16 +10:00
pretty Create const block DefIds in typeck instead of ast lowering 2024-05-28 13:38:43 +00:00
run-make Rollup merge of #125683 - Oneirical:patience-testing-test, r=jieyouxu 2024-06-05 01:14:30 -07:00
run-make-fulldeps Remove tests/run-make-fulldeps/pretty-expanded 2024-06-05 00:51:09 +10:00
run-pass-valgrind rustfmt tests/run-pass-valgrind/. 2024-06-04 09:53:02 +10:00
rustdoc Update code format and tests 2024-06-04 13:49:39 +02:00
rustdoc-gui Rollup merge of #124738 - notriddle:notriddle/search-form-js, r=GuillaumeGomez 2024-05-07 18:12:54 +02:00
rustdoc-js rustfmt tests/rustdoc-js/. 2024-06-04 14:15:06 +10:00
rustdoc-js-std rustdoc-search: add parser for & syntax 2024-04-19 14:31:21 -07:00
rustdoc-json rustfmt tests/rustdoc-json/. 2024-06-04 14:15:19 +10:00
rustdoc-ui Rollup merge of #125667 - oli-obk:taintify, r=TaKO8Ki 2024-06-04 08:52:12 -04:00
ui Rollup merge of #125622 - oli-obk:define_opaque_types15, r=compiler-errors 2024-06-05 18:21:11 +02:00
ui-fulldeps Make top-level rustc_parse functions fallible. 2024-06-05 10:38:03 +10:00
COMPILER_TESTS.md