Skip to content
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

feat: Add diagnostic for incorrect _ expressions (typed holes) #14916

Merged
merged 1 commit into from
May 28, 2023

Conversation

Veykril
Copy link
Member

@Veykril Veykril commented May 28, 2023

No description provided.

@rustbot rustbot added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label May 28, 2023
@HKalbasi
Copy link
Member

This is nice! Though _ is accepted in nightly in some places (for example let x: [u8; 5] = [2; _]; works in nightly IIRC), we may want not making error in those cases.

@Veykril
Copy link
Member Author

Veykril commented May 28, 2023

Oh ye, that is a good catch (I should add some negative tests in general)

@Veykril Veykril force-pushed the typed-hole branch 3 times, most recently from cfd240b to 6c4c85c Compare May 28, 2023 12:54
@Veykril Veykril changed the title Add diagnostic for _ expressions (typed holes) feat: Add diagnostic for _ expressions (typed holes) May 28, 2023
@Veykril
Copy link
Member Author

Veykril commented May 28, 2023

@bors r+

@bors
Copy link
Collaborator

bors commented May 28, 2023

📌 Commit 8bc826d has been approved by Veykril

It is now in the queue for this repository.

@bors
Copy link
Collaborator

bors commented May 28, 2023

⌛ Testing commit 8bc826d with merge 505fd09...

@Veykril Veykril changed the title feat: Add diagnostic for _ expressions (typed holes) feat: Add diagnostic for incorrect _ expressions (typed holes) May 28, 2023
@bors
Copy link
Collaborator

bors commented May 28, 2023

☀️ Test successful - checks-actions
Approved by: Veykril
Pushing 505fd09 to master...

@bors bors merged commit 505fd09 into rust-lang:master May 28, 2023
@Veykril Veykril deleted the typed-hole branch May 28, 2023 15:37
@lnicola
Copy link
Member

lnicola commented May 29, 2023

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-review Status: Awaiting review from the assignee but also interested parties.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants