This compiles:
---
/* test.c */
struct test;
typedef struct test test;
---
This doesn't:
---
/* test.c */
typedef struct test test;
---
Both programs should be considered the same.
Comment #1 by dlang-bot — 2021-08-10T10:09:04Z
@ibuclaw created dlang/dmd pull request #12970 "fix Issue 22160 - importC: Error: redeclaring `module test` as `struct test`" fixing this issue:
- fix Issue 22160 - importC: Error: redeclaring `module test` as `struct test`
https://github.com/dlang/dmd/pull/12970
Comment #2 by dlang-bot — 2021-08-10T20:49:06Z
dlang/dmd pull request #12970 "fix Issue 22160 - importC: Error: redeclaring `module test` as `struct test`" was merged into master:
- a998fc401ab493c824ed7cd4e809d18396ad0f0c by Iain Buclaw:
fix Issue 22160 - importC: Error: redeclaring `module test` as `struct test`
https://github.com/dlang/dmd/pull/12970