Emilio Cobos Álvarez
021d09db2b
bitflags: Make more operations constexpr.
2022-06-07 18:48:48 +02:00
Emilio Cobos Álvarez
2e2c87e58a
Fix changelog typo.
2022-06-07 16:20:24 +02:00
Emilio Cobos Álvarez
b9a2209228
Version bump.
2022-06-07 16:19:40 +02:00
Emilio Cobos Álvarez
597b033ccf
constant: Support suffixes for integers that otherwise would be narrowed.
2022-06-07 16:19:40 +02:00
Jason Orendorff
a79a10d9a6
Fix specialization of SomeType<N>
when N
is a const parameter.
...
Fixes #761 .
2022-05-25 10:41:44 +02:00
Jason Orendorff
13b31ddcc2
Minor refactor of ConstExpr::load().
2022-05-25 10:40:32 +02:00
Jason Orendorff
dde68cc439
Support char-like byte literals.
2022-05-25 10:40:32 +02:00
Jason Orendorff
caf69c8800
Support bool and char literals as arguments to const generics.
2022-05-25 10:40:32 +02:00
Jason Orendorff
eb5c979912
Rename ArrayLength to ConstExpr.
2022-05-25 10:40:32 +02:00
Jason Orendorff
c732069b2e
New type GenericParam represents a generic parameter.
2022-05-09 16:13:39 +02:00
Jason Orendorff
13c0a4a2e8
New type GenericArguments represents actual arguments to generics.
2022-05-09 16:13:39 +02:00
Emilio Cobos Álvarez
798cfab52b
v0.23.0
2022-04-21 18:48:00 +02:00
Emilio Cobos Álvarez
305ccfe746
constant: Make const.allow_constexpr default to true.
2022-04-21 18:48:00 +02:00
Emilio Cobos Álvarez
15e1131160
constant: Allow more constexpr constants.
2022-04-21 18:48:00 +02:00
Mike Hommey
a0ab62469a
Update syn dependency to at least 1.0.88
...
While the Cargo.lock has 1.0.89, the current minimal version in Cargo.toml
is 1.0.3, which cannot parse modern Rust code. This leads to some
downstreams (*cough* Debian) inadvertently building cbindgen against
older versions of syn and the resulting cbindgen, even if it is the last
version, not being able to parse recent Rust code.
Bumping the version in Cargo.toml alleviates this to some extent. A
quick scan of the syn logs suggests 1.0.88 is the last version where
parsing support relevant to stable Rust syntax was added.
2022-04-21 13:13:40 +02:00
Stovent
8cfd4570cc
Fix #753
2022-04-21 13:03:21 +02:00
Emilio Cobos Álvarez
8604b2c0b7
v0.22.0
2022-04-19 11:29:52 +02:00
kavoor
5b418d968c
Support rename rule for union body members.
...
Closes #751 .
2022-04-19 11:22:04 +02:00
Emilio Cobos Álvarez
770f352375
constant: Add support for other expressions WebRender uses.
2022-04-14 23:41:07 +02:00
Emilio Cobos Álvarez
882af0b563
constant: Add support for associated constant expressions.
...
These are useful for bitflags.
2022-04-14 23:41:07 +02:00
Jordan Rose
20ddfffb6a
Fix regression in CamelCase rename rule (should be lowerCamelCase)
2022-04-05 22:54:52 +02:00
Emilio Cobos Álvarez
09284108eb
enumeration: simplify standard types in variants.
...
Fixes #745
2022-04-04 20:25:01 +02:00
Vadim Petrochenkov
aeb81934d1
Avoid generating and writing bindings when called recursively
...
from a build script.
2022-03-31 21:59:54 +02:00
Vadim Petrochenkov
ca7a942ce5
Cython: Omit per-variant tags in unions generated for Rust enums
...
The common `tag` should already be enough, al other tags are identical to it.
In Cython case they only create noise because the declarations only introduce names and do not determine layouts.
2022-03-31 21:57:16 +02:00
Emilio Cobos Álvarez
522759e92b
Update various dependencies.
...
Closes #743
2022-03-27 17:37:09 +02:00
Emilio Cobos Álvarez
b3de1dc4b4
v0.21.0
...
* Update MSRV to 1.54.0
* Update clap to 3.1.
* Update heck to 0.4.0
* unraw identifiers
* Honor documentation_length in Cython.
* Add documentation_style to with short and full options
* Map RawFd to Int
* Respect remove_underscores config when prefixing name to enum
2022-03-25 18:52:23 +01:00
messense
d4e508d6d1
Update MSRV to 1.54.0
...
Closes #740
2022-03-25 18:49:21 +01:00
messense
2f1202e8c5
Update clap to 3.1
2022-03-25 18:49:17 +01:00
messense
293fcc53ff
Update heck to 0.4.0
2022-03-25 18:47:33 +01:00
Emilio Cobos Álvarez
88d4b99774
Remove etesync from readme.
...
Closes #739
2022-03-25 18:42:36 +01:00
Chris Cleveland
b94318a8b7
Update docs.md
2022-01-09 05:12:50 +01:00
Emilio Cobos Álvarez
fc4ab1ca55
Remove wgpu-native from users.
...
Closes #725
2021-12-25 18:56:43 +01:00
Emilio Cobos Álvarez
c407b7da90
Address clippy lint.
2021-12-14 16:19:21 +01:00
Olivier Goffart
ed8d94619f
unraw the identifiers
...
Fixes https://github.com/eqrion/cbindgen/issues/410
2021-12-14 16:18:41 +01:00
Emilio Cobos Álvarez
11228f6b6f
Silence some dead_code warnings.
2021-11-02 11:34:12 +01:00
Emilio Cobos Álvarez
a1694cd57c
ir: Honor documentation_length in Cython.
2021-11-02 11:31:30 +01:00
Sean McArthur
0e3f9bd9cb
Add documentation_style to with short and full options
2021-11-02 11:13:49 +01:00
Marc-André Lureau
24c130bd9c
Map RawFd to Int
...
On all Unix systems, RawFd is defined as c_int.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
2021-11-02 11:09:22 +01:00
Emilio Cobos Álvarez
577b041933
tests: Add a test for #708
2021-08-24 11:44:51 +02:00
Adam Wilson
cbd4260bdc
Respect remove_underscores config when prefixing name to enum
...
Fixes #705
Closes #708
2021-08-24 11:44:30 +02:00
Emilio Cobos Álvarez
41506d5aeb
v0.20.0
...
* Add Builder::with_using_namespaces (#688 ).
* Ignore PhantomPinned (#695 ).
* Simplify Pin<T> to T (#697 ).
* Update --pretty=expanded to -Zunpretty=expanded (#706 ).
2021-07-29 14:29:15 +02:00
Jan-Erik Rediger
34299aef56
Don't use check
profile when expanding code on a release build
2021-07-28 11:52:29 +02:00
Jan-Erik Rediger
6c96c8ab95
Update --pretty=expanded to -Zunpretty=expanded
...
`--pretty` is gone as of https://github.com/rust-lang/rust/pull/83491
2021-07-28 11:52:29 +02:00
Emilio Cobos Álvarez
57add9c860
Fix some clippy lints.
2021-06-21 13:25:53 +02:00
Kendall Koning
63c1043dfb
Simplify Pin<T> to T
...
cbindgen already simplifies `MaybeUninit<T>` and `ManuallyDrop<T>` to `T`. This adds `Pin<T>` as well.
2021-06-19 20:48:57 +02:00
Joel Dice
ccd1f0e9ec
add Builder::with_using_namespaces
2021-06-19 10:52:01 +02:00
Kendall Koning
4e394493d6
Ignore PhantomPinned
...
cbindgen already ignores `PhantomData`. It should ignore
`PhantomPinned` for the same reasons.
Closes #695
Fixes #694
2021-06-19 10:35:08 +02:00
Emilio Cobos Álvarez
2d20c4b151
Move the target-guessing code from #676 to its own function.
...
Seems nicer.
2021-04-12 17:22:12 +02:00
Jon Gjengset
93c06c5c9d
Only fetch dependencies for current platform by default ( #676 )
...
cbindgen invokes `cargo metadata` to find the sources of dependencies so
that it can generate bindings for types that originate in those
dependencies. However, `cargo metadata` defaults to fetching
dependencies for _all_ platforms unless it is specifically invoked with
the `--filter-platforms` argument.
This PR makes cbindgen pass that argument to `cargo metadata` using the
host platform, which will significantly reduce the time of the first
call in cases where the dependency tree includes many target-specific
dependencies.
Fixes #675 .
2021-04-12 17:13:09 +02:00
Emilio Cobos Álvarez
d9e490ce8b
v0.19.0
...
* Simplify types in generics (#663 )
* Use --profile=check for macro expansion (#671 )
* Use exported name to prefix enum variants (#672 )
* Fix path attribute handling in inline submodules (#679 )
* Fix a stack overflow with some recursive typedefs (#680 )
2021-04-08 18:18:10 +02:00