These previously failed because they used '/' as the path separator
instead of '\'. While both are accepted on Windows, the latter is
preferred and used to construct new paths, such as the path of imported
header files. This inconsistency led to distinct buffer ID numbers being
created (since paths are not canonicalized in BufferIdentIDMap), leading
-verify to fail to associate the error emitted from the included file
with the error expected in the -verify-additional-file file.
This patch re-enables these tests but uses %{fs-sep} in place of '/', to
ensure the appropriate path separator is used for the platform where the
test is run.
rdar://148928101
ClangImporter can now import non-public members as of be73254cdc and 66c2e2c52b, but doing so triggers some latent ClangImporter bugs in projects that don't use or need those non-public members.
This patch introduces a new experimental feature flag, ImportNonPublicCxxMembers, that guards against the importation of non-public members while we iron out those latent issues. Adopters of the SWIFT_PRIVATE_FILEID feature introduced in bdf22948ce can enable this flag to opt into importing private members they wish to access from Swift.
rdar://145569473
This patch introduces an a C++ class annotation, SWIFT_PRIVATE_FILEID,
which will specify where Swift extensions of that class will be allowed
to access its non-public members, e.g.:
class SWIFT_PRIVATE_FILEID("MyModule/MyFile.swift") Foo { ... };
The goal of this feature is to help C++ developers incrementally migrate
the implementation of their C++ classes to Swift, without breaking
encapsulation and indiscriminately exposing those classes' private and
protected fields.
As an implementation detail of this feature, this patch introduces an
abstraction for file ID strings, FileIDStr, which represent a parsed pair
of module name/file name.
rdar://137764620