]> git.bitcoin.ninja Git - ldk-c-bindings/commit
Prefer `Option_` mappings for more types over transparent mappings
authorMatt Corallo <git@bluematt.me>
Fri, 23 Sep 2022 16:12:46 +0000 (16:12 +0000)
committerMatt Corallo <git@bluematt.me>
Fri, 23 Sep 2022 16:12:46 +0000 (16:12 +0000)
commitc9189547e9e06bec4303a5d23de8bf3387a8e9a0
treefde63aaf0a5ed94d32fc31d01badec6e4cce5c70
parenteee35240eed2d8c8d104ed1b086fcd9b37f9db88
Prefer `Option_` mappings for more types over transparent mappings

In general, the explicit `Option_` mappings are easier for
downstream bindings to match against, and clearer for users anyway.
Sadly, originally we were trying to avoid them where possible, so
some types default to transparent mappings. Here we swap the
default, at least for manually-mapped types, with a few explicit
exceptions (that probably should be changed as well).
c-bindings-gen/src/types.rs