diff options
author | Christian Poveda Ruiz <31802960+pvdrz@users.noreply.github.com> | 2022-11-10 10:43:02 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-11-10 10:43:02 -0500 |
commit | db4ea32e2d810e765a4c40479e053d0a61a875cf (patch) | |
tree | e08d61cdcfb3aa5c7e4fafb0f8dc4eb6261bbfcd /bindgen/codegen/impl_debug.rs | |
parent | ed3aa90cd4c4e1e59d15942414a6dbc586ac1ed4 (diff) |
Handle the `const struct *` and `struct *` patterns (#2304)
Given that C keeps a different namespace for `struct`/`enum`/`union` and `typedef` aliases. The
following patterns
```c
typedef const struct foo {
void *inner;
} *foo;
typedef struct bar {
void *inner;
} *bar;
```
are valid C code and produces both a `struct` and a pointer called `foo`
and `bar` in different namespaces. Given that Rust does not make this
distinction, we add the `_ptr` prefix to the pointer type aliases to
avoid any name collisions.
Diffstat (limited to 'bindgen/codegen/impl_debug.rs')
0 files changed, 0 insertions, 0 deletions