Commit Graph

1 Commits

Author SHA1 Message Date
Dmitri Gribenko
61d4793970 Added tests for edge cases in importing and mangling C structs
Some of the patterns in the new test header are special-cased by
ClangImporter (for example, the names of typedefs become names of
imported structs).

Nested structs have been historically imported in Swift according to C
rules, that is, structs lexically declared nested in other structs are
imported into the global namespace anyway. For the same reason, C
structs have been mangled in Swift names as if they are declared in the
global namespace. These rules are problematic when importing C++, see
https://bugs.swift.org/browse/SR-12803.
2020-05-15 18:50:19 +02:00