diff options
-rw-r--r-- | tests/expectations/tests/issue-833.rs | 10 | ||||
-rw-r--r-- | tests/headers/issue-833.hpp | 8 |
2 files changed, 18 insertions, 0 deletions
diff --git a/tests/expectations/tests/issue-833.rs b/tests/expectations/tests/issue-833.rs new file mode 100644 index 00000000..9de7c64f --- /dev/null +++ b/tests/expectations/tests/issue-833.rs @@ -0,0 +1,10 @@ +/* automatically generated by rust-bindgen */ + + +#![allow(dead_code, non_snake_case, non_camel_case_types, non_upper_case_globals)] + +#[repr(C)] pub struct nsTArray<T> { pub hdr: *const T } + +extern "C" { + pub fn func() -> *mut nsTArray<::std::os::raw::c_int>; +} diff --git a/tests/headers/issue-833.hpp b/tests/headers/issue-833.hpp new file mode 100644 index 00000000..ea0d2add --- /dev/null +++ b/tests/headers/issue-833.hpp @@ -0,0 +1,8 @@ +// bindgen-flags: --generate functions --whitelist-function func --raw-line "#[repr(C)] pub struct nsTArray<T> { pub hdr: *const T }" + +template<typename T> +class nsTArray { + T* mHeader; +}; + +extern "C" nsTArray<int>* func(); |