Age | Commit message (Collapse) | Author | |
---|---|---|---|
2020-03-16 | Added some initial constraints to the objective-c bindgen stuff | Sebastian Imlay | |
2020-02-17 | var: Constant arrays of const elements should not generate `static mut`s. | Emilio Cobos Álvarez | |
Fixes #1727 | |||
2020-02-03 | options: Add an opt-in to recover the size_t behavior removed in 5d38f2ac. | Emilio Cobos Álvarez | |
2020-02-02 | ir: codegen: Handle too large bitfield units. | Emilio Cobos Álvarez | |
By not generating various code for it. In the future, we could improve on this by splitting contiguous bitfield units, if needed, so that we can implement them without dealing with rust array derive limits. Fixes #1718 | |||
2020-01-29 | ir: Account for packedness when computing bitfield sizes. | Emilio Cobos Álvarez | |
Fixes #1716 | |||
2020-01-13 | codegen: Max guaranteed alignment is 8 (with u64), not target pointer width. | Emilio Cobos Álvarez | |
2020-01-13 | Remove padding for over-aligned structs when we support repr(align). | Emilio Cobos Álvarez | |
Before repr(align), we could only safely guarantee up to 8-bytes of alignment (I think the pointer-width check is a more conservative way of doing that, in practice, because I _think_ u64 is 8-byte aligned even for smaller targets). So when we may generate a potentially-under-aligned struct, we always used to pad it so as to guarantee that at least the size (and thus reads from rust for C-allocated structs) was fine. But if we support repr(align), then the above is always unneeded. | |||
2020-01-05 | Added non-keyword support to objective-c methods. | Sebastian Imlay | |
2020-01-05 | An initial implementation of objective-c generics for #1259 (#1702) | simlay | |
2019-12-13 | Remove size_t to usize conversion rule | Conor McAvity | |
2019-12-11 | tests: Minor rustc warning fixes. | Emilio Cobos Álvarez | |
2019-12-11 | Add support for wasm_import_module | Jasper-Bekkers | |
2019-11-14 | Add newtype enum style | David Vo | |
This adds an enum style similar to the existing bitfield style, without the bitwise operator impls. Closes: #1669 | |||
2019-11-14 | Warn rather than panic on unknown namespace prefix | Jon Gjengset | |
When a #defined token was used before a namespace, like so (#1676): #define nssv_inline_ns inline nssv_inline_ns namespace literals {} bindgen would crash when encountering the unknown token preceding the namespace token. This is because we don't get to see "past" the ifdef to the underlying token. The true fix to this is to find a way to extract ifdef info through clang, but for the time being we simply change the panic into a warning when such a token is encountered, and then proceed as if it were empty. Fixes #1676. | |||
2019-11-09 | Update tests from transmute to 'as' casting | Elichai Turkel | |
2019-11-08 | Option to use #[repr(transparent)] structs instead of type aliasing. | Joseph Rafael Ferrer | |
2019-11-08 | Update and add tests for MaybeUninit | Elichai Turkel | |
2019-11-03 | Do not generate implementation for clone for FAM | David Frey | |
Flexible array members are represented in the generated binding by a struct __IncompleteArrayField<T>. Since such members do not contain any information about how big they are, it is impossible to automatically clone or copy them, either in C or rust. Fixes #1431. | |||
2019-10-22 | Add `disable_nested_struct_naming` option (#1610) | oblique | |
The following structs have different names for C and C++. In case of C they are visible as `foo` and `bar`. In case of C++ they are visible as `foo` and `foo::bar`. By default bindgen follows C++ naming to avoid generating duplicate names. With this option the following structs will be named as `foo` and `bar` instead of `foo` and `foo_bar`. ``` struct foo { struct bar { } b; }; ``` In case of an unnamed definition we build the canonical name from the inner most named definition. For example the following will generate `baz__bindgen_ty_1`: ``` struct foo { struct bar { struct baz { struct { } u; } z; } b; }; ``` This option should be used only for C headers. It is needed in some rare situations where user used another code generator that already mangled nested definitions. A real life example is [asn1c] with `-fcompound-names` option. [asn1c]: https://github.com/vlm/asn1c | |||
2019-10-22 | codegen: Handle opaque aliases to enums correctly. | Emilio Cobos Álvarez | |
Opaque types don't use the path to their aliased type but an opaque type like an array or primitive with the right alignment. Fixes #1599. | |||
2019-10-14 | Fix bitfield-linux-32.hpp to not hit #1538. | Emilio Cobos Álvarez | |
The test was failing. | |||
2019-10-14 | tests: Remove support for test directive that is no longer used. | Emilio Cobos Álvarez | |
ae0fdf7a5519a175d887389c80399234637bdc29 changed the setup for the only test that actually used this. | |||
2019-10-14 | Run `cargo fmt` on the main crate. | Emilio Cobos Álvarez | |
2019-10-14 | tests: Reformat test crate. | Emilio Cobos Álvarez | |
Now that the rustfmt configuration is different we need to do this to not generate unexpected failures. | |||
2019-10-14 | tests: Use the same rustfmt configuration as the parent directory. | Emilio Cobos Álvarez | |
This allows us to workaround/fix https://github.com/rust-lang/rustfmt/issues/3799 | |||
2019-10-14 | tests: Fix some warning in the test crate. | Emilio Cobos Álvarez | |
2019-10-14 | Add llvm 9.0 to CI. | Emilio Cobos Álvarez | |
2019-10-14 | Update test expectations for libclang 9.0. | Emilio Cobos Álvarez | |
2019-10-14 | Create clang-9-specific test directory, as a copy of clang-5. | Emilio Cobos Álvarez | |
2019-10-14 | tests: Look at expectations/tests/libclang-9 expectations. | Emilio Cobos Álvarez | |
2019-10-14 | tests: Look at the more specific tests first, but don't require specific ↵ | Emilio Cobos Álvarez | |
expectations for all llvm versions. | |||
2019-10-08 | Fix BitfieldUnit constructor to handle 64 bit wide bitfields on 32 bit. | Cameron McCormack | |
Fixes #1639. | |||
2019-10-03 | Use c_void from core when --use-core is specified | Kyle Tomsic | |
`c_void` is available as `::std::os::raw::c_void` and `::core::ffi::c_void`. If the "--use-core" option is specified (but no --ctypes-prefix is provided), we should emit `::core::ffi::c_void` rather than the `std` one. | |||
2019-09-17 | Rustfmt. | Emilio Cobos Álvarez | |
2019-09-02 | Update syn related dependencies and bump version | Bastien Orivel | |
2019-07-23 | Don't emit #[repr(align(0))] for empty unions (#1595) | Patrick Marks | |
2019-07-15 | Fix layout computation for union forward declarations (#1593) | Patrick Marks | |
2019-07-10 | ir: Properly find the layout of incomplete arrays. | Emilio Cobos Álvarez | |
So as to not pad stuff incorrectly, or needlessly add extra alignment, for example. Fixes #1589 | |||
2019-07-09 | Improve workaround for LLVM bug when evaluating value-dependent expressions. | Emilio Cobos Álvarez | |
Using the canonical type makes it work across typedefs. Fixes #1590 | |||
2019-06-25 | Make BlockPointer's canonical type in IR be itself, not as if it is an alias. | Garrett Nickel | |
2019-06-12 | Add missing --rust-target flags on test case. | uk | |
See https://github.com/rust-lang/rust-bindgen/pull/1575#discussion_r293079226 | |||
2019-06-11 | Hopefully fixes automated tests for #1554. | uk | |
See https://github.com/rust-lang/rust-bindgen/pull/1575#discussion_r292230729 | |||
2019-06-10 | Add support for non_exhaustive rustified enums. | uk | |
Implements the feature discussed in https://github.com/rust-lang/rust-bindgen/issues/1554. | |||
2019-06-06 | For rust-target >= 1.30, make __IncompleteArrayField::new a const fn | Colin Wallace | |
2019-06-06 | For rust-target >= 1.30, make __BindgenUnionField::new a const fn | Colin Wallace | |
2019-06-06 | FIX #1571: For rust-target >= 1.30, make __BindgenBitfieldUnit::new a const fn | Colin Wallace | |
2019-06-06 | Remove the parameter bounds for __BindgenBitfieldUnit::new | Colin Wallace | |
This will enable `new` to be changed to a `const fn` in a future patch: `const fn`s do not support trait bounds. | |||
2019-05-22 | Added tests with typedef for array pointers | Elichai Turkel | |
2019-05-22 | Added tests for array pointers | Elichai Turkel | |
2019-05-15 | Add test cases for x86 Windows calling conventions. | Michael Woerister | |