rust/tests
bors 789ee5e433 Auto merge of #108576 - megakorre:rustdock_additional_typecheck_before_clean, r=GuillaumeGomez
rustdoc: run more HIR validation to mirror rustc

# Explanation

While investigating these issues: https://github.com/rust-lang/rust/issues/107093, https://github.com/rust-lang/rust/issues/106079
I thought it maybe would be useful to test running `rustdoc` on all rust files under `tests/ui` grepping for files that causes any ICEs.
And these are the files I found would cause ICEs.
```
// These are handled by this fix.
tests/ui/late-bound-lifetimes/mismatched_arg_count.rs
tests/ui/associated-consts/issue-102335-const.rs
tests/ui/const-generics/generic_const_exprs/issue-102768.rs
tests/ui/const-generics/const-arg-type-arg-misordered.rs
tests/ui/generic-associated-types/parse/trait-path-type-error-once-implemented.rs
tests/ui/typeck/issue-88643.rs
tests/ui/typeck/issue-75889.rs
tests/ui/typeck/issue-83621-placeholder-static-in-extern.rs
// These are not they will still produce a ICE after this change
tests/ui/limits/issue-56762.rs
tests/ui/union/projection-as-union-type-error-2.rs
tests/ui/union/projection-as-union-type-error.rs
```

I reduces the issues handled by this PR down to the tests added in the PR. That includes the linked issues.
But the 3 files that are not handled I will leave for a future PR.

This PR adds the `type_collecting` step from `hir_analysis::check_crate` to the rustdoc typechecks.
It had the following comment on it.
```
// this ensures that later parts of type checking can assume that items
// have valid types and not error
```
Adding the check report the same errors as rustc does for these input.
And not ICE when the lint checker walks the HIR or when in the `rustdoc::clean` pass.

This PR updates the expected errors of some existing rustdoc-ui tests (some now report less errors).
These new reported errors does mirror the errors reported by rustc.

# Performance
It does more checking so it will probably regress. We should run ``@bors` try `@rust-timer` queue` and see.

# Discussion

Maybe instead of calling a subset of the checks in `hir_analysis::check_crate` and having comments that say they should be kept in sync. We could instead call `check_crate` directly and pass in some flag. Maybe `check_toplevel_signatures_only` or something like that. That flag would have to skip most of the checks in that function tough.
2023-03-30 15:21:22 +00:00
..
assembly Ignore LVI incompatible assembly tests on sgx platform 2023-03-10 16:04:37 +01:00
auxiliary
codegen update codegen test expectations 2023-03-27 17:44:33 +00:00
codegen-units Use unused_generic_params from crate metadata 2023-03-14 16:33:12 +00:00
debuginfo Bless debuginfo test. 2023-03-13 18:24:48 +00:00
incremental Rollup merge of #105793 - lukas-code:circular-deps, r=Mark-Simulacrum 2023-03-19 15:33:55 +05:30
mir-opt Rollup merge of #109664 - m-ou-se:format-args-placeholder-span, r=oli-obk 2023-03-29 14:07:28 +05:30
pretty Auto merge of #108148 - parthopdas:master, r=oli-obk 2023-03-20 03:24:27 +00:00
run-make Stabilize a portion of 'once_cell' 2023-03-29 18:04:44 -04:00
run-make-fulldeps Rollup merge of #109213 - oli-obk:cstore, r=cjgillot 2023-03-22 22:44:40 +01:00
run-pass-valgrind
rustdoc Rollup merge of #109509 - ehuss:overlapping-tests, r=Mark-Simulacrum 2023-03-30 21:07:00 +09:00
rustdoc-gui Rollup merge of #109633 - GuillaumeGomez:fix-go-to-only-setting, r=notriddle 2023-03-27 08:46:53 +02:00
rustdoc-js rustdoc: add support for type filters in arguments and generics 2023-03-20 22:41:57 -07:00
rustdoc-js-std rustdoc: add support for type filters in arguments and generics 2023-03-20 22:41:57 -07:00
rustdoc-json rustdoc + rustdoc-json support for non_lifetime_binders 2023-03-28 16:50:49 +00:00
rustdoc-ui rustdoc: tidy excess whitespace 2023-03-30 15:46:34 +02:00
ui Auto merge of #109769 - JohnTitor:rollup-7n2bnpg, r=JohnTitor 2023-03-30 12:44:25 +00:00
ui-fulldeps Auto merge of #109224 - oli-obk:smir, r=pnkfelix 2023-03-30 02:59:25 +00:00
COMPILER_TESTS.md