mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
[Sema] Treat open as we do public for testable and private imports
This should be NFC but will help streamline implementation of access-level on imports enforcement.
This commit is contained in:
@@ -3155,6 +3155,7 @@ bool SourceFile::hasTestableOrPrivateImport(
|
||||
case AccessLevel::Internal:
|
||||
case AccessLevel::Package:
|
||||
case AccessLevel::Public:
|
||||
case AccessLevel::Open:
|
||||
// internal/public access only needs an import marked as @_private. The
|
||||
// filename does not need to match (and we don't serialize it for such
|
||||
// decls).
|
||||
@@ -3173,8 +3174,6 @@ bool SourceFile::hasTestableOrPrivateImport(
|
||||
desc.options.contains(ImportFlags::PrivateImport);
|
||||
}
|
||||
});
|
||||
case AccessLevel::Open:
|
||||
return true;
|
||||
case AccessLevel::FilePrivate:
|
||||
case AccessLevel::Private:
|
||||
// Fallthrough.
|
||||
|
||||
Reference in New Issue
Block a user