File tree 5 files changed +10
-7
lines changed 5 files changed +10
-7
lines changed Original file line number Diff line number Diff line change @@ -13,7 +13,7 @@ fn extract_args(a: &syn::FnArg) -> &syn::PatType {
13
13
#[ allow( clippy:: test_attr_in_doctest) ]
14
14
/// Macro for generating byond binds
15
15
/// Usage:
16
- /// ```
16
+ /// ```ignore
17
17
/// use byondapi::prelude::*;
18
18
/// #[byondapi::bind]
19
19
/// fn example() {Ok(ByondValue::null())}
@@ -23,7 +23,7 @@ fn extract_args(a: &syn::FnArg) -> &syn::PatType {
23
23
///
24
24
/// ```
25
25
/// Then generate the bindings.dm file with
26
- /// ```
26
+ /// ```ignore
27
27
/// #[test]
28
28
/// fn generate_binds() {
29
29
/// byondapi::byondapi_macros::generate_bindings(env!("CARGO_CRATE_NAME"));
Original file line number Diff line number Diff line change 1
1
[package ]
2
2
name = " byondapi"
3
- version = " 0.4.8 "
3
+ version = " 0.4.9 "
4
4
authors = [
" tigercat2000 <[email protected] >" ]
5
5
edition = " 2021"
6
6
description = " Idiomatic Rust bindings for BYONDAPI"
@@ -13,7 +13,7 @@ exclude = [".vscode/*"]
13
13
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
14
14
15
15
[dependencies ]
16
- byondapi-sys = { path = " ../byondapi-sys" , version = " 0.11.1 " }
16
+ byondapi-sys = { path = " ../byondapi-sys" , version = " 0.11.2 " }
17
17
byondapi-macros = { path = " ../byondapi-macros" , version = " 0.1.2" }
18
18
libloading = " 0.8.4"
19
19
inventory = " 0.3.15"
Original file line number Diff line number Diff line change @@ -7,7 +7,9 @@ struct CallbackData<F: FnOnce() -> ByondValue + Send> {
7
7
callback : Option < F > ,
8
8
}
9
9
10
- extern "C" fn trampoline < F : FnOnce ( ) -> ByondValue + Send > ( data : * mut c_void ) -> CByondValue {
10
+ extern "C-unwind" fn trampoline < F : FnOnce ( ) -> ByondValue + Send > (
11
+ data : * mut c_void ,
12
+ ) -> CByondValue {
11
13
let data = unsafe { Box :: from_raw ( data as * mut CallbackData < F > ) } ;
12
14
( data. callback . unwrap ( ) ) ( ) . into_inner ( )
13
15
}
Original file line number Diff line number Diff line change 1
1
[package ]
2
2
name = " byondapi-sys"
3
- version = " 0.11.1 "
3
+ version = " 0.11.2 "
4
4
authors = [
" tigercat2000 <[email protected] >" ]
5
5
edition = " 2021"
6
6
description = " Raw bindgen bindings for byondapi"
Original file line number Diff line number Diff line change 1
- use bindgen:: callbacks:: ParseCallbacks ;
1
+ use bindgen:: { callbacks:: ParseCallbacks , Abi } ;
2
2
use std:: path:: { Path , PathBuf } ;
3
3
4
4
fn main ( ) {
@@ -55,6 +55,7 @@ fn generate_all() {
55
55
. header ( wrapper. to_string_lossy ( ) )
56
56
. dynamic_library_name ( "ByondApi" )
57
57
. dynamic_link_require_all ( true )
58
+ . override_abi ( Abi :: CUnwind , "Byond.*" )
58
59
// Also make headers included by main header dependencies of the build
59
60
. parse_callbacks ( Box :: new ( bindgen:: CargoCallbacks :: new ( ) ) )
60
61
. parse_callbacks ( Box :: new ( DoxygenCallbacks ) ) ;
You can’t perform that action at this time.
0 commit comments