[clang-tools-extra] Fix #35272: Don't replace typedefs in extern c scope (PR #69102)

Piotr Zegar via cfe-commits cfe-commits at lists.llvm.org
Sun Oct 15 05:36:03 PDT 2023


PiotrZSL wrote:

I got mixed feelings about this. Simply we can use 'using' within extern "C", there is nothing wrong with this. using/typedef doesn't haven linkage, that just type alias. And extern "C" does not impact it. In oryginal issue I think someone mistook extern "C" into something where only "C" code should be put, and that's not true. All what extern "C" does it's using C style symbol mangling for functions inside.

The only reason to not use 'using' in extern 'C' would be just readability, to avoid some confusion.
As for this change, release notes & doc is needed.

https://github.com/llvm/llvm-project/pull/69102


More information about the cfe-commits mailing list