-
Notifications
You must be signed in to change notification settings - Fork 55
'call to unsafe function requires unsafe function or block' with rustc 1.26.0-nightly (f5631d9ac 2018-03-24) #79
Comments
It's caused by rust-lang/rust#49194 @alexcrichton can you pls release a new version that fixes this but without depending on proc-macro2 0.2 nightly? (that would cause lots of other problems) The best would be a 0.1.1 version that "just" fixes this but otherwise works the same as 0.1.0? Thanks! |
I have a branch where I cherry-picked all commits that are not 0.2 specific, I use it currently until a fixed version is in cargo: https://github.com/ngg/futures-await/commits/0.1 |
@ngg for some reason I got this error while using your version:
|
@bbigras It's strange... Did it work with the official 0.1.0 version? Can you send a file for which it fails (or a link to some crate it does not work with)? |
@alexcrichton having 0.1.1 would sure be a good thing to have as it would take some time for everyone to move to futures 0.2 which is a prereq for futures-await master. |
For now it would be possible to just throw the two lines that error in an unsafe block, i'm not sure why resuming generators are now unsafe or if this would have a negative impact on futures-await, but it seems like an easy fix. |
Resuming generators is now unsafe because the generator may or may not be an immovable generator. For |
nice to know, thanks |
Using @ngg's branch solved this. Could you please send a pull request here and get 0.1.1 released? The current situation is no good. |
This change has broken a lot of crates, mine included. What's preventing this issue from being closed? |
Sorry about being broken for so long! Everyone involved in maintaining this crate has been pretty busy with other things. Now that the 0.2 version has been upstreamed into rust-lang-nursery/futures-rs, I think I'm going to revert this repo to just track version 0.1. Then we can merge a fix for this in & upload an 0.1.1 version. |
If anyone wants to take #86 over and get it passing CI, I will gladly merge it & release 0.1.1. Otherwise I will eventually get it to pass CI hopefully this week some time. |
Uploaded futures-await 0.1.1 which should work on current nightlies 🎉 |
Thanks a lot, it works perfectly :) |
Hi. I use nightly rust on my project and got this compile error today after rustup update.
Is there anything need to be upgraded?
Thanks
The text was updated successfully, but these errors were encountered: