Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
std: Reexport std::rt::unwind::try in std::thread #23651
This commit provides a safe, but unstable interface for the
There are two primary reasons that this function was previously marked
The new API is now called
@brson ah yes sorry, I feel like I often do carry around a little bit too much in my head!
The motivation for this is that today it is impossible to both safely and in a
@aturon and I talked a lot at lunch today about whether this should be safe or not, and if so what it should look like. We ended up concluding that this signature is both a balance between usability and continuing the current trend of preventions against exception safety problems. An example of this trend is how
Does that help clear things up, do you think that a change like this requires an RFC?
Right now I only have two reservations: that this is in the 'ffi' module - although that's the critical use case, it doesn't otherwise have anything to do with ffi; that it takes the 'try' name, when we already have one 'try' concept, and there is a design for another in the pipelines, and this is the conservative version of try, that could presumably be superseded someday.
@brson do you have suggestions for what you might prefer to see this name or located? I thought the
changed the title from
std: Reexport std::rt::unwind::try in std::ffi
@alexcrichton std: Reexport std::rt::unwind::try in std::thread
Mar 24, 2015
I am happy with these changes (thanks again @brson for catching these issues).
Note that we will likely want a version without the