mirror of
https://github.com/openharmony/third_party_rust_bindgen.git
synced 2026-07-25 07:25:25 -04:00
2cb371a7ed
If we don't, then eddyb's recent layout optimizations will do unexpected things to them. We also need to handle empty `enum`s without variants. When `repr(C)` is on a Rust `enum`, it cannot be empty, so we need to add a dummy.
16 lines
477 B
C
16 lines
477 B
C
// bindgen-flags: --rustified-enum '.*Rustified.*' --constified-enum-module '.*Module.*' -- -x c++ --std=c++14
|
|
|
|
// Constified is default, so no flag for that.
|
|
|
|
enum EmptyConstified {};
|
|
enum EmptyRustified {};
|
|
enum EmptyModule {};
|
|
|
|
enum class EmptyClassRustified : char {};
|
|
enum class EmptyClassConstified : char {};
|
|
enum class EmptyClassModule : char {};
|
|
|
|
enum class ForwardClassRustified : char;
|
|
enum class ForwardClassConstified : char;
|
|
enum class ForwardClassModule : char;
|