]> git.bitcoin.ninja Git - ldk-c-bindings/commit
Avoid mapping optionals as owned pointers
authorMatt Corallo <git@bluematt.me>
Wed, 22 Sep 2021 02:46:10 +0000 (02:46 +0000)
committerMatt Corallo <git@bluematt.me>
Thu, 23 Sep 2021 18:35:11 +0000 (18:35 +0000)
commitc4cf32b1fa04571d4a7fdadca4554c6a6d045119
tree14335540b885b939b0bb5ec7f2e791319cf05b25
parent11063db7153ff78d289674672099d69af0ff6a8d
Avoid mapping optionals as owned pointers

Using an owned pointer to map an optional turned out to be quite
annoying to avoid downstream memory issues. Instead, we use the
much more explicit `COption_TypeZ` enums everywhere.

This also fixes Option-al mapping of enums.
c-bindings-gen/src/blocks.rs
c-bindings-gen/src/types.rs