diff options
| author | Kazu Hirata <kazu@google.com> | 2022-06-25 11:55:57 -0700 |
|---|---|---|
| committer | Kazu Hirata <kazu@google.com> | 2022-06-25 11:55:57 -0700 |
| commit | aa8feeefd3ac6c78ee8f67bf033976fc7d68bc6d (patch) | |
| tree | d207b35cfb445636f41204bcfe51f6ca3a94a3ba /clang/lib/CodeGen/CodeGenModule.cpp | |
| parent | b8df4093e4d82c67a419911a46b63482043643e5 (diff) | |
Don't use Optional::hasValue (NFC)
Diffstat (limited to 'clang/lib/CodeGen/CodeGenModule.cpp')
| -rw-r--r-- | clang/lib/CodeGen/CodeGenModule.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/clang/lib/CodeGen/CodeGenModule.cpp b/clang/lib/CodeGen/CodeGenModule.cpp index 17b8e6bc1b47..34d8b3a7d360 100644 --- a/clang/lib/CodeGen/CodeGenModule.cpp +++ b/clang/lib/CodeGen/CodeGenModule.cpp @@ -2826,12 +2826,12 @@ bool CodeGenModule::isProfileInstrExcluded(llvm::Function *Fn, CodeGenOptions::ProfileInstrKind Kind = getCodeGenOpts().getProfileInstr(); // First, check the function name. Optional<bool> V = ProfileList.isFunctionExcluded(Fn->getName(), Kind); - if (V.hasValue()) + if (V) return *V; // Next, check the source location. if (Loc.isValid()) { Optional<bool> V = ProfileList.isLocationExcluded(Loc, Kind); - if (V.hasValue()) + if (V) return *V; } // If location is unknown, this may be a compiler-generated function. Assume |
