Skip to content

Commit ed96ce0

Browse files
committed
Drop #[no_mangle] from *_write_void to make cbindgen not export
cbindgen recently switched to exporting all `#[no_mangle]` and `extern "C"` functions. Our `*_write_void` methods are internal-only but we'd marked them `#[no_mangle]`, which resulted in them spuriously appearing in `lightning.h`.
1 parent 78310f9 commit ed96ce0

File tree

1 file changed

+0
-1
lines changed

1 file changed

+0
-1
lines changed

c-bindings-gen/src/main.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,6 @@ fn maybe_convert_trait_impl<W: std::io::Write>(w: &mut W, trait_path: &syn::Path
9595

9696
writeln!(w, "}}").unwrap();
9797
if has_inner {
98-
writeln!(w, "#[no_mangle]").unwrap();
9998
writeln!(w, "pub(crate) extern \"C\" fn {}_write_void(obj: *const c_void) -> crate::c_types::derived::CVec_u8Z {{", for_obj).unwrap();
10099
writeln!(w, "\tcrate::c_types::serialize_obj(unsafe {{ &*(obj as *const native{}) }})", for_obj).unwrap();
101100
writeln!(w, "}}").unwrap();

0 commit comments

Comments
 (0)