Skip to content

Fix suggestion to constrain trait for method to be found - #65242

Merged
bors merged 1 commit into
rust-lang:masterfrom
estebank:contrain-trait-sugg
Oct 16, 2019
Merged

Fix suggestion to constrain trait for method to be found#65242
bors merged 1 commit into
rust-lang:masterfrom
estebank:contrain-trait-sugg

Conversation

@estebank

Copy link
Copy Markdown
Contributor

Fix#65044.

@rust-highfive

Copy link
Copy Markdown
Contributor

r? @varkor

(rust_highfive has picked a reviewer for you, use r? to override)

@rust-highfiverust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Oct 9, 2019

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The current method is getting rather large; would be good to subdivide things.

Copy link
Copy Markdown
ContributorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I feel that splitting this method would lead to with smaller methods with too many arguments, beyond the point for to be worth it.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That suggests that a struct should be invented to carry the additional state.

Comment threadsrc/test/ui/suggestions/constrain-trait.stderr Outdated
@bors

bors commented Oct 12, 2019

Copy link
Copy Markdown
Collaborator

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

Comment threadsrc/librustc_typeck/check/method/suggest.rs Outdated
@varkor

Copy link
Copy Markdown
Contributor

Looks good. r=me with spelling fix.

@estebank

Copy link
Copy Markdown
ContributorAuthor

Rebased.

@bors r=varkor

@bors

bors commented Oct 15, 2019

Copy link
Copy Markdown
Collaborator

📌 Commit dee53d7 has been approved by varkor

@borsbors 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 Oct 15, 2019
Centril added a commit to Centril/rust that referenced this pull request Oct 15, 2019
Fix suggestion to constrain trait for method to be found
Fixrust-lang#65044.
@CentrilCentril mentioned this pull request Oct 15, 2019
tmandry added a commit to tmandry/rust that referenced this pull request Oct 15, 2019
Fix suggestion to constrain trait for method to be found
Fixrust-lang#65044.
@tmandrytmandry mentioned this pull request Oct 15, 2019
bors added a commit that referenced this pull request Oct 15, 2019
Rollup of 14 pull requests
Successful merges:
- #64603 (Reducing spurious unused lifetime warnings.)
- #64623 (Remove last uses of gensyms)
- #65235 (don't assume we can *always* find a return type hint in async fn)
- #65242 (Fix suggestion to constrain trait for method to be found)
- #65265 (Cleanup librustc mir err codes)
- #65293 (Optimize `try_expand_impl_trait_type`)
- #65307 (Try fix incorrect "explicit lifetime name needed")
- #65308 (Add long error explanation for E0574)
- #65353 (save-analysis: Don't ICE when resolving qualified type paths in struct members)
- #65389 (Return `false` from `needs_drop` for all zero-sized arrays.)
- #65402 (Add troubleshooting section to PGO chapter in rustc book.)
- #65425 (Optimize `BitIter`)
- #65438 (Organize `never_type` tests)
- #65444 (Implement AsRef<[T]> for List<T>)
Failed merges:
- #65390 (Add long error explanation for E0576)
r? @ghost
@bors
bors merged commit dee53d7 into rust-lang:masterOct 16, 2019
@estebank
estebank deleted the contrain-trait-sugg branch November 9, 2023 05:18
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

restrict type parameter Self error is unclear.

5 participants

@estebank@rust-highfive@bors@varkor@Centril