-
-
Notifications
You must be signed in to change notification settings - Fork 14.4k
Tidying up tests/ui/issues 15 tests [6/N] #150216
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
This PR modifies |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That seems more of a label; I didn't found a place for a break. you can maybe search for the "break" keyword in tests/ui to find a better place
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I thought it was similar to array-break-length.rs, so I made it array-break-length-2 and merged it here.
Would it be a good idea to move all array-break-length.rs to another directory?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I feel like, yeah, it seems reasonable to me to move both of them into some more related directory
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A directory just for break and continue would probably be tests/ui/for-loop-while. But this test seems like it would be appropriate for tests/closures.
Merged with existing similar tests. https://github.com/rust-lang/rust/blob/main/tests/ui/closures/closure-array-break-length.rs
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I feel like it's more about cast, and I believe I saw a directory for cast stuff somewhere before, maybe even in this PR
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, I thought this test was similar to the existing tests/ui/mismatched_types/cast-rfc0401.rs test, so I placed it in the mismatched directory.
Now I moved them all to cast, and deleted the duplicate test, cast-rfc0401-2.rs!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
cast-rfc0401.rs also should be in cast directory :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh, I guess I didn't explain it well enough.
Merge mismatched_types/cast-rfc0401-2.rs and mismatched_types/cast-rfc0401.rs and move to cast/cast-rfc0401-fail.rs
(cast/cast-rfc0401.rs aready exist for success case)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Well, it seems like both mismatched_types/cast-rfc0401.rs and cast/cast-rfc0401.rs already existing? So, if I understood it correctly, I think it would be reasonable to merge them
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
To recap, there are currently no tests for rfc0401 in the mismatched_types directory, and there used to be a cast/cast-rfc0401.rs test for the success case.
And I merged the three tests below into cast/cast-rfc0401-fail.rs:
- https://github.com/rust-lang/rust/blob/main/tests/ui/mismatched_types/cast-rfc0401.rs
- https://github.com/rust-lang/rust/blob/main/tests/ui/cast/cast-rfc0401-2.rs
- https://github.com/rust-lang/rust/blob/main/tests/ui/issues/issue-21554.rs (
mismatched_types/cast-rfc0401-2.rs)
Ultimately, the success cases are in cast/cast-rfc0401.rs and the failure cases are in cast/cast-rfc0401-fail.rs.
|
Thanks for taking time on this! |
|
Thanks for the review:) |
|
force-push after each reflection seems a bit more confusing. |
|
Looks good, seems like it's ready to be squased |
add comment to closure-move-use-after-move-diagnostic.rs add comment to missing-operator-after-float.rs add comment to closure-array-break-length.rs add comment to box-lifetime-argument-not-allowed.rs add comment to const-return-outside-fn.rs add comment to drop-conflicting-impls.rs add comment to unbalanced-doublequote-2.rs add comment to borrow-immutable-deref-box.rs add comment to for-in-const-eval.rs add comment to borrowck-annotated-static-lifetime.rs cleaned up cast-rfc0401.rs add comment to nll-anon-to-static.rs add comment to cast-to-dyn-any.rs add comment to missing-associated-items.rs add comment to enum-discriminant-missing-variant.rs
|
@bors r+ rollup |
Tidying up tests/ui/issues 15 tests [6/N] > [!NOTE] > Intermediate commits are intended to help review, but will be squashed add comment commit prior to merge. part of rust-lang#133895 r? Kivooeo
Rollup of 5 pull requests Successful merges: - #150182 (Don't export upstream monomorphizations from compiler-builtins) - #150216 (Tidying up tests/ui/issues 15 tests [6/N]) - #150308 (Update bors configuration) - #150311 (Avoid using env::temp when linking a binary) - #150314 (rustc-dev-guide subtree update) r? `@ghost` `@rustbot` modify labels: rollup
Rollup of 6 pull requests Successful merges: - #149800 (Fix ICE in normalization during closure capture analysis (#149746)) - #150182 (Don't export upstream monomorphizations from compiler-builtins) - #150216 (Tidying up tests/ui/issues 15 tests [6/N]) - #150308 (Update bors configuration) - #150314 (rustc-dev-guide subtree update) - #150319 (use new term in description of --target) r? `@ghost` `@rustbot` modify labels: rollup
Rollup of 6 pull requests Successful merges: - rust-lang/rust#149800 (Fix ICE in normalization during closure capture analysis (rust-lang/rust#149746)) - rust-lang/rust#150182 (Don't export upstream monomorphizations from compiler-builtins) - rust-lang/rust#150216 (Tidying up tests/ui/issues 15 tests [6/N]) - rust-lang/rust#150308 (Update bors configuration) - rust-lang/rust#150314 (rustc-dev-guide subtree update) - rust-lang/rust#150319 (use new term in description of --target) r? `@ghost` `@rustbot` modify labels: rollup
Rollup of 6 pull requests Successful merges: - rust-lang/rust#149800 (Fix ICE in normalization during closure capture analysis (rust-lang/rust#149746)) - rust-lang/rust#150182 (Don't export upstream monomorphizations from compiler-builtins) - rust-lang/rust#150216 (Tidying up tests/ui/issues 15 tests [6/N]) - rust-lang/rust#150308 (Update bors configuration) - rust-lang/rust#150314 (rustc-dev-guide subtree update) - rust-lang/rust#150319 (use new term in description of --target) r? `@ghost` `@rustbot` modify labels: rollup
Rollup of 6 pull requests Successful merges: - rust-lang/rust#149800 (Fix ICE in normalization during closure capture analysis (rust-lang/rust#149746)) - rust-lang/rust#150182 (Don't export upstream monomorphizations from compiler-builtins) - rust-lang/rust#150216 (Tidying up tests/ui/issues 15 tests [6/N]) - rust-lang/rust#150308 (Update bors configuration) - rust-lang/rust#150314 (rustc-dev-guide subtree update) - rust-lang/rust#150319 (use new term in description of --target) r? `@ghost` `@rustbot` modify labels: rollup
Note
Intermediate commits are intended to help review, but will be squashed add comment commit prior to merge.
part of #133895
r? Kivooeo