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

compile async await function error #53989

Brooooooklyn opened this issue Sep 6, 2018 · 2 comments

compile async await function error #53989

Brooooooklyn opened this issue Sep 6, 2018 · 2 comments


Copy link

@Brooooooklyn Brooooooklyn commented Sep 6, 2018

Error message:
error: internal compiler error: librustc/infer/region_constraints/ cannot relate bound region: ReLateBound(DebruijnIndex(1), BrAnon(2)) <= '_#0r


thread 'main' panicked at 'Box<Any>', librustc_errors/
query stack during panic:
#0 [evaluate_obligation] evaluating trait selection obligation `impl std::future::Future: std::marker::Send`
#1 [typeck_tables_of] processing `main`
#2 [typeck_tables_of] processing `main::{{closure}}`
#3 [type_of] processing `main::{{closure}}`
end of query stack
error: aborting due to previous error
Copy link

@paracat paracat commented Nov 25, 2018

while not exactly the same, i have created a commit for the project reflow that produces a compiler error involving bound region and DebruijnIndex

It happened when I'm trying to replace &mut TcpStream with AsyncRead

the commit that comes before this one compiles fine. this should make it easier for the Rust team to locate the error

this is probably related to #55809
with some minor changes i can produce that error

Copy link

@cramertj cramertj commented Feb 22, 2019

Closing as duplicate of #57084.

@cramertj cramertj closed this Feb 22, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
4 participants