2

Check lazy type aliases for well-formedness by fmease · Pull Request #114228 · r...

 1 year ago
source link: https://github.com/rust-lang/rust/pull/114228
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
neoserver,ios ssh client

Check lazy type aliases for well-formedness #114228

Conversation

Contributor

Previously we didn't check if T: Mul holds given lazy type Alias<T> = <T as Mul>::Output;.
Now we do. It only makes sense.

@rustbot label F-lazy_type_alias

r? @oli-obk

SDesya74 reacted with hooray emoji

rustbot

added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. F-lazy_type_alias #![feature(lazy_type_alias)]

labels

Jul 29, 2023

|| ty.has_opaque_types()

|| ty.has_inherent_projections()

{

// Bounds of lazy type aliases and on eager ones that contain opaque types or inherent

Contributor

Author

Let me know if the phrasing is ok, bounds sounds ambiguous to me. One might wonder it refers to the bounds on the generic parameters (which is the case) or if it refers to the item bounds (i.e. the B in type T: B = … which is obviously invalid for type aliases).

Contributor

Author

Update: Done.
At this point I'm asking myself if we should introduce a separate UI test folder for lazy_type_alias.
Including this PR, there are 3 UI tests and 2 rustdoc tests for lazy type aliases ^^.

matthiaskrgr, workingjubilee, and Nilstrieb reacted with thumbs up emoji

rustbot

added A-testsuite Area: The testsuite used to check the correctness of rustc T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)

labels

Jul 30, 2023

This comment has been minimized.

Contributor

☔ The latest upstream changes (presumably #114226) made this pull request unmergeable. Please resolve the merge conflicts.

Contributor

@bors r+ rollup

Contributor

pushpin Commit 0ca4328 has been approved by oli-obk

It is now in the queue for this repository.

bors

added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion.

and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties.

labels

Jul 31, 2023

bors

merged commit 95b7116 into

rust-lang:master

Jul 31, 2023

11 checks passed

rust-timer

added a commit to rust-lang-ci/rust that referenced this pull request

Jul 31, 2023

fmease

deleted the wf-lazy-ty-aliases branch

July 31, 2023 18:32

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

No reviews

Assignees

oli-obk

Labels
A-testsuite Area: The testsuite used to check the correctness of rustc F-lazy_type_alias #![feature(lazy_type_alias)] S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects

None yet

Milestone

1.73.0

Development

Successfully merging this pull request may close these issues.

None yet

5 participants

About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK