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

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

Merged
merged 1 commit into from Oct 16, 2019

Conversation

@estebank
Copy link
Contributor

estebank commented Oct 9, 2019

Fix #65044.

@rust-highfive

This comment has been minimized.

Copy link
Collaborator

rust-highfive commented Oct 9, 2019

r? @varkor

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

}
_ => {
has_bounds = !param.bounds.is_empty();
debug!("suggest_traits_to_import {:?} {:?}", hir.get(id), generics);

This comment has been minimized.

Copy link
@Centril

Centril Oct 9, 2019

Member

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

This comment has been minimized.

Copy link
@estebank

estebank Oct 9, 2019

Author Contributor

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

This comment has been minimized.

Copy link
@Centril

Centril Oct 10, 2019

Member

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

@bors

This comment has been minimized.

Copy link
Contributor

bors commented Oct 12, 2019

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

@varkor

This comment has been minimized.

Copy link
Member

varkor commented Oct 13, 2019

Looks good. r=me with spelling fix.

@estebank estebank force-pushed the estebank:contrain-trait-sugg branch from 57f456e to dee53d7 Oct 15, 2019
@estebank

This comment has been minimized.

Copy link
Contributor Author

estebank commented Oct 15, 2019

Rebased.

@bors r=varkor

@bors

This comment has been minimized.

Copy link
Contributor

bors commented Oct 15, 2019

📌 Commit dee53d7 has been approved by varkor

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

Fix rust-lang#65044.
bors added a commit that referenced this pull request Oct 15, 2019
Rollup of 9 pull requests

Successful merges:

 - #65094 (Prefer statx on linux if available)
 - #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)
 - #65307 (Try fix incorrect "explicit lifetime name needed")
 - #65389 (Return `false` from `needs_drop` for all zero-sized arrays.)
 - #65402 (Add troubleshooting section to PGO chapter in rustc book.)
 - #65435 (Fix #64153)
 - #65438 (Organize `never_type`  tests)
 - #65444 (Implement AsRef<[T]> for List<T>)

Failed merges:

r? @ghost
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

Fix rust-lang#65044.
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:master Oct 16, 2019
4 checks passed
4 checks passed
pr Build #20191015.32 succeeded
Details
pr (Linux mingw-check) Linux mingw-check succeeded
Details
pr (Linux x86_64-gnu-llvm-6.0) Linux x86_64-gnu-llvm-6.0 succeeded
Details
pr (LinuxTools) LinuxTools succeeded
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
5 participants
You can’t perform that action at this time.