use new llvm::Optional APIs to fix deprecation warnings

This commit is contained in:
Erik Eckstein
2023-06-28 14:28:38 +02:00
parent 746dd9823a
commit 6b1697eb06
20 changed files with 28 additions and 28 deletions

View File

@@ -3232,7 +3232,7 @@ RestrictedImportKind SourceFile::getRestrictedImportKind(const ModuleDecl *modul
ImportAccessLevel
SourceFile::getImportAccessLevel(const ModuleDecl *targetModule) const {
assert(Imports.hasValue());
assert(Imports.has_value());
// Leave it to the caller to avoid calling this service for a self import.
// We want to return AccessLevel::Public, but there's no import site to return.