-
Notifications
You must be signed in to change notification settings - Fork 111
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
Implement mrb_raise with panic #35
Comments
This will allow removing the dependency on Eval and Funcall would implement "catch" with |
Add the test for the TODO in artichoke/ferrocarril#168. Psuedo code, called in a loop 100 times. This is expected to leak 100MB. unsafe extern "C" throws(mrb, slf) {
let interp = unwrap_interpreter(mrb);
let s = Box::new(std::iter::repeat("a").take(1024 * 1024).collect::<String>());
RuntimeError::raise(interp, "oh no")
} |
This is currently blocked on rust-lang/rfcs#2699. |
The linked RFC resulted in unwind ABIs: https://rust-lang.github.io/rfcs/2945-c-unwind-abi.html Upstream tracking issue: rust-lang/rust#74990 |
The C-unwind ABI has been implemented and is currently on nightly: rust-lang/rust#76570. |
this is happening! rust-lang/rfcs#2945 (comment) |
The Rust team has put out a call for testing on the `c_unwind` feature and associated `C-unwind` ABI: - rust-lang/rfcs#2945 (comment) I intend to implement mruby's exception unwinding using Rust's panic infrastructure: - #35 This commit changes the Rust toolchain to nightly for this test. Merging this experiment will be blocked on the `C-unwind` ABI making it to stable.
`mruby-error` implements `mrb_protect` and `mrb_ensure`. These two functions are used to stop the propagation of exception unwinding in mruby, which natively uses either `setjmp`/`longjmp` or C++'s `catch` and `throw`. I intend to reimplement these functions in Rust using Rust panics: `std::panic::catch_unwind` and `std::panic::panic_any`. See: - #35
The Rust team has put out a call for testing on the `c_unwind` feature and associated `C-unwind` ABI: - rust-lang/rfcs#2945 (comment) I intend to implement mruby's exception unwinding using Rust's panic infrastructure: - #35 This commit changes the Rust toolchain to nightly for this test. Merging this experiment will be blocked on the `C-unwind` ABI making it to stable.
`mruby-error` implements `mrb_protect` and `mrb_ensure`. These two functions are used to stop the propagation of exception unwinding in mruby, which natively uses either `setjmp`/`longjmp` or C++'s `catch` and `throw`. I intend to reimplement these functions in Rust using Rust panics: `std::panic::catch_unwind` and `std::panic::panic_any`. See: - #35
The Rust team has put out a call for testing on the `c_unwind` feature and associated `C-unwind` ABI: - rust-lang/rfcs#2945 (comment) I intend to implement mruby's exception unwinding using Rust's panic infrastructure: - #35 This commit changes the Rust toolchain to nightly for this test. Merging this experiment will be blocked on the `C-unwind` ABI making it to stable.
`mruby-error` implements `mrb_protect` and `mrb_ensure`. These two functions are used to stop the propagation of exception unwinding in mruby, which natively uses either `setjmp`/`longjmp` or C++'s `catch` and `throw`. I intend to reimplement these functions in Rust using Rust panics: `std::panic::catch_unwind` and `std::panic::panic_any`. See: - #35
The Rust team has put out a call for testing on the `c_unwind` feature and associated `C-unwind` ABI: - rust-lang/rfcs#2945 (comment) I intend to implement mruby's exception unwinding using Rust's panic infrastructure: - #35 This commit changes the Rust toolchain to nightly for this test. Merging this experiment will be blocked on the `C-unwind` ABI making it to stable.
`mruby-error` implements `mrb_protect` and `mrb_ensure`. These two functions are used to stop the propagation of exception unwinding in mruby, which natively uses either `setjmp`/`longjmp` or C++'s `catch` and `throw`. I intend to reimplement these functions in Rust using Rust panics: `std::panic::catch_unwind` and `std::panic::panic_any`. See: - #35
The Rust team has put out a call for testing on the `c_unwind` feature and associated `C-unwind` ABI: - rust-lang/rfcs#2945 (comment) I intend to implement mruby's exception unwinding using Rust's panic infrastructure: - #35 This commit changes the Rust toolchain to nightly for this test. Merging this experiment will be blocked on the `C-unwind` ABI making it to stable.
`mruby-error` implements `mrb_protect` and `mrb_ensure`. These two functions are used to stop the propagation of exception unwinding in mruby, which natively uses either `setjmp`/`longjmp` or C++'s `catch` and `throw`. I intend to reimplement these functions in Rust using Rust panics: `std::panic::catch_unwind` and `std::panic::panic_any`. See: - #35
The Rust team has put out a call for testing on the `c_unwind` feature and associated `C-unwind` ABI: - rust-lang/rfcs#2945 (comment) I intend to implement mruby's exception unwinding using Rust's panic infrastructure: - #35 This commit changes the Rust toolchain to nightly for this test. Merging this experiment will be blocked on the `C-unwind` ABI making it to stable.
`mruby-error` implements `mrb_protect` and `mrb_ensure`. These two functions are used to stop the propagation of exception unwinding in mruby, which natively uses either `setjmp`/`longjmp` or C++'s `catch` and `throw`. I intend to reimplement these functions in Rust using Rust panics: `std::panic::catch_unwind` and `std::panic::panic_any`. See: - #35
The Rust team has put out a call for testing on the `c_unwind` feature and associated `C-unwind` ABI: - rust-lang/rfcs#2945 (comment) I intend to implement mruby's exception unwinding using Rust's panic infrastructure: - #35 This commit changes the Rust toolchain to nightly for this test. Merging this experiment will be blocked on the `C-unwind` ABI making it to stable.
`mruby-error` implements `mrb_protect` and `mrb_ensure`. These two functions are used to stop the propagation of exception unwinding in mruby, which natively uses either `setjmp`/`longjmp` or C++'s `catch` and `throw`. I intend to reimplement these functions in Rust using Rust panics: `std::panic::catch_unwind` and `std::panic::panic_any`. See: - #35
The gymnastics and sad times in artichoke/ferrocarril#168 become unnecessary if we have a memory safe unwind.
panic
is exactly that.Implement
mrb_raise
,mrb_raisef
andmrb_protect
in Rust inmrb-sys
exported to C so libmruby can use them.The text was updated successfully, but these errors were encountered: