Releases: google/autocxx
Releases · google/autocxx
v0.16.0
What's Changed
- The main improvement here is continued support for the
moveit
crate, and its ability to move/copy construct non-trivial C++ objects around on the Rust stack. The support is still not finished - you still can't, for instance, pass such objects by value into existing C++ functions - but it's further on. In this version you can move non-trivial C++ objects around on the Rust stack, make copies etc. subject to the availability of move/copy constructors on the C++ side.- Implement
CopyNew
trait in #752 - Implement
MoveNew
trait in #752 - Implement
Drop
trait in #758. (Previously stack-allocated C++ objects didn't get their destructors called) - Bump up to a new version of
moveit
which allows us toemplace
intoUniquePtr
(#757). Note that there is a known bug/limitation here, #772 - Correctly identify deleted move constructors in #738
- Hopefully (and this is the big big) identify and populate all the implicit constructors that C++ standards specify - #760. This is error-prone so if there are problems, this is probably why, and a new
block_constructors!
directive is added on the assumption that I've messed something up here and a workaround is needed.
- Implement
- Another significant improvement is that all the autogenerated type names for
AutocxxConcrete
types are now more descriptive by @adetaylor in #764 - Correctly spot types which are abstract due to private pure virtual functions by @adetaylor in #750
- Add
cxx
to dependencies in Readme example by @psmit in #741 - Update s2geometry URI by @adetaylor in #746
- Regularize bindgen annotations. by @adetaylor in #734. This is a step towards potentially being able to upstream some of these annotations into the upstream bindgen, though it's a long way off still
- A couple of fixes for the
autocxx-reduce
pipeline by @adetaylor in #747, #749 - Fixing comments in non-trivial C++ types example. by @adetaylor in #748
- Fixing some garbage collection issues in #759
- Some miscellaneous test changes
- Add additional test for issue 486. by @adetaylor in #736, #737
- Switch test logging dependencies due to deprecation. by @adetaylor in #740
New Contributors
Full Changelog: v0.15.0...v0.16.0
v0.15.0
Build related changes
- Allow
--cxx-impl-annotationx
. by @adetaylor in #705. This allows the C++ side of bindings to be marked as exported from shared objects. - Allow customizable path to cxx.h and cxxgen.h by @adetaylor in #730
- Pass thru static/runtime features. by @adetaylor in #732
New feature: early integration with moveit
crate
- Retain struct sizes: WIP by @adetaylor in #720
- Support stack allocating C++ objects. by @adetaylor in #724
- Fix unnecessary 'unsafe' warning. by @adetaylor in #729
Other new features
- Add conversion traits for standard integers. by @adetaylor in #726
- Implement
AsRef
to cast derived classes to base classes by @adetaylor in #663
Successful code generation in more circumstances (or at least successfully ignoring APIs we can't generate)
- Ignore protected and private types by @benesch in #711 (thanks!)
- Fix virtual functions inside nested structs by @adetaylor in #694
- Ignore rvalue references. by @adetaylor in #733 (thanks to @benesch for the test in #715)
Testing and internal changes
- Test for private inner classes by @adetaylor in #714
- Test for issue #717 by @adetaylor in #721
New Contributors
Full Changelog: v0.14.0...v0.15.0
v0.14.0
What's Changed
- All related to
subclass!
support:- Fix spurious semicolon in generated code. by @adetaylor in #690
- Fix excessive and incorrect code generation when overriding a pure virtual superclass function by @adetaylor in #702
- Fix overridden methods on subclasses by @adetaylor in #695
- Allow overriding protected methods by @adetaylor in #696
- Mode to make hermetic reproduction test cases (
AUTOCXX_REPRO_CASE
) by @adetaylor in #699
Full Changelog: v0.13.2...v0.14.0
v0.13.2
What's Changed
- Ignore protected methods instead of failing to generate such classes by @adetaylor in #679
- Document
Builder
objects. by @adetaylor in #680 - Redo README file. by @adetaylor in #683 (and #684)
Full Changelog: v0.13.1...v0.13.2
v0.13.1
What's Changed
- No moves that would eliminate return value optimization by @adetaylor in #654
- Cease reject members with references by @adetaylor in #653
- Fix constructors for nested classes. by @adetaylor in #655
- Test for part of issue 642. by @adetaylor in #656
- Alert on abstract nested by @adetaylor in #660
- Simplify type generation code by @adetaylor in #659
- Adding
unsafe
to subclass functions where necessary by @adetaylor in #661 - Artisinal chromium example by @adetaylor in #657
- Add explicit message for non-pub subclass structs. by @adetaylor in #662
- Fix for build bug. by @adetaylor in #664
- Bump to autocxx-bindgen 0.59.4. by @adetaylor in #665
- Support variable-length ints in POD structs. by @adetaylor in #669
- Building an example on CI which was missed. by @adetaylor in #671
- Revise to 0.13.1. by @adetaylor in #672
Full Changelog: v0.13.0...v0.13.1
v0.13.0
- Subclass improvements:
- Allow subclassing of C++ classes in namespaces.
- Support arbitrary constructors for superclasses.
- Simplify subclass default traits.
- Some rejigging of the directives/macro names. Breaking change but only if you already used the subclass support.
- Allow unit structs to be subclasses.
- Improve specificity of error messages around missing dependencies.
- Provide the option to suppress system headers.
- Provide an autodiscovery mode which attempts to spot use of
ffi::
to avoid any allowlist at all. - Provide
#[extern_rust_fun]
and#[extern_rust_type]
attribute macros to allow exporting of arbitrary Rust code to C++. - Bump bindgen version.
- Make compatible with
resolver = 2
. - Breaking change Deprecated some of the
builder
methods and replaced them with, err, a Builder builder.
v0.12.0
- Revised minimum Rust version to 1.54
- Bumped
env_logger
and removed dependency onindoc
to make the transitive dependency tree smaller - New APIs in
autocxx_build
; old ones still exist but are deprecated - move to the new ones - Synthesize
make_unique
for types with default constructors (fixes #122) - Add an experimental "dynamic discovery" mode (see
autocxx_build::Builder::auto_allowlist
) which enables you to remove thegenerate
directives - Subclasses:
- Simplified example by adding prelude and some derive macros
- Removed the need to explicitly call a C++ peer constructor; the subclass codegen now does this automatically unless there are multiple or complex constructors in which case you'll need to implement a trait to choose
- Improved panics on re-entrancy and similar error states
- Filed issues for all known limitations and mentioned in documentation
- Much documentation
- Filenames of generated .rs files on disk have changed - they're no longer based on a hash of the directives. This should reduce filesystem pollution through leaking old versions.
v0.11.2
- Minimum Rust version now 1.55
- Added
rust_type!
to allow passing references to Rust types within C++ APIs - Added support for
rust::Box
to allow passing opaque Rust types into and out of C++ APIs - Added very early support for creating Rust subclasses of C++ superclasses, subject to a bunch of constraints. See
examples/subclass/src/main.rs
. - Upgrade to
cxx
1.0.54