[BETA]: parse array lengths without stripping const blocks#152237
[BETA]: parse array lengths without stripping const blocks#152237BoxyUwU wants to merge 1 commit intorust-lang:betafrom
Conversation
|
|
|
7745534 to
01703e3
Compare
|
Some changes occurred in src/tools/rustfmt cc @rust-lang/rustfmt |
|
(added the rustfmt tests) |
|
The job Click to see the possible cause of the failure (guessed by this bot) |
|
The job Click to see the possible cause of the failure (guessed by this bot) |
|
The job Click to see the possible cause of the failure (guessed by this bot) |
|
See #152393 for a passing CI run where we don't die to rustdoc lol |
(The commit in this PR will need to cherry-picked into another beta backport rollup which includes the commits that also removes the flaky rustdoc tests) |
[beta] backports, plus stable versions in stdarch - Replace `stdarch` version placeholders with 1.94 - Parse ident with allowing recovery when trying to diagnose #151249 - Revert enabling `outline-atomics` on various platforms #151896 - Revert doc attribute parsing errors to future warnings #151952 - Remove the 4 failing tests from rustdoc-gui #152194 - Remove rustdoc GUI flaky test #152116 - Align `ArrayWindows` trait impls with `Windows` #151613 - Fix suppression of `unused_assignment` in binding of `unused_variable` #151556 - layout: handle rigid aliases without params #151814 - Fix missing unused_variables lint when using a match guard #151990 - Partially revert "resolve: Update `NameBindingData::vis` in place" #152498 - [BETA]: parse array lengths without stripping const blocks #152237 r? cuviper
|
This was included in #152187. |
Avoids rust-lang/rustfmt#6788
When parsing
const { ... }in array lengths we were stripping the const block and just parsing a block expression which is wrong. This PR reverts the behaviour back to the (previously stable) logic of just parsing an anon const.This PR breaks
min_generic_const_argsbut that doesn't matter its an unstable feature :) I've just deleted the mGCA tests which were affected by this. A proper fix for this is in #152234 but I don't think that should be backported as it's too involved.cc @rust-lang/rustfmt
r? oli-obk