[all-commits] [llvm/llvm-project] 19aff0: [Analysis] Use std::nullopt instead of None (NFC)

kazutakahirata via All-commits all-commits at lists.llvm.org
Fri Dec 2 19:43:18 PST 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 19aff0f37dd68ee51e78b764c0ce629ae73d1eef
      https://github.com/llvm/llvm-project/commit/19aff0f37dd68ee51e78b764c0ce629ae73d1eef
  Author: Kazu Hirata <kazu at google.com>
  Date:   2022-12-02 (Fri, 02 Dec 2022)

  Changed paths:
    M llvm/include/llvm/Analysis/IRSimilarityIdentifier.h
    M llvm/include/llvm/Analysis/InlineAdvisor.h
    M llvm/include/llvm/Analysis/InlineCost.h
    M llvm/include/llvm/Analysis/LoopAccessAnalysis.h
    M llvm/include/llvm/Analysis/LoopCacheAnalysis.h
    M llvm/include/llvm/Analysis/MemoryDependenceAnalysis.h
    M llvm/include/llvm/Analysis/ObjCARCAnalysisUtils.h
    M llvm/include/llvm/Analysis/ObjCARCUtil.h
    M llvm/include/llvm/Analysis/ScalarEvolution.h
    M llvm/include/llvm/Analysis/TargetLibraryInfo.h
    M llvm/include/llvm/Analysis/TargetTransformInfo.h
    M llvm/include/llvm/Analysis/TargetTransformInfoImpl.h
    M llvm/include/llvm/Analysis/ValueLattice.h
    M llvm/lib/Analysis/AliasAnalysis.cpp
    M llvm/lib/Analysis/AliasAnalysisSummary.cpp
    M llvm/lib/Analysis/BasicAliasAnalysis.cpp
    M llvm/lib/Analysis/BlockFrequencyInfo.cpp
    M llvm/lib/Analysis/BlockFrequencyInfoImpl.cpp
    M llvm/lib/Analysis/BranchProbabilityInfo.cpp
    M llvm/lib/Analysis/CFLAndersAliasAnalysis.cpp
    M llvm/lib/Analysis/InlineAdvisor.cpp
    M llvm/lib/Analysis/InlineCost.cpp
    M llvm/lib/Analysis/InlineSizeEstimatorAnalysis.cpp
    M llvm/lib/Analysis/LazyValueInfo.cpp
    M llvm/lib/Analysis/Lint.cpp
    M llvm/lib/Analysis/LoopAccessAnalysis.cpp
    M llvm/lib/Analysis/LoopCacheAnalysis.cpp
    M llvm/lib/Analysis/LoopInfo.cpp
    M llvm/lib/Analysis/LoopNestAnalysis.cpp
    M llvm/lib/Analysis/MemoryBuiltins.cpp
    M llvm/lib/Analysis/MemorySSA.cpp
    M llvm/lib/Analysis/OptimizationRemarkEmitter.cpp
    M llvm/lib/Analysis/ProfileSummaryInfo.cpp
    M llvm/lib/Analysis/ReplayInlineAdvisor.cpp
    M llvm/lib/Analysis/ScalarEvolution.cpp
    M llvm/lib/Analysis/StratifiedSets.h
    M llvm/lib/Analysis/TensorSpec.cpp
    M llvm/lib/Analysis/VFABIDemangling.cpp
    M llvm/lib/Analysis/ValueTracking.cpp

  Log Message:
  -----------
  [Analysis] Use std::nullopt instead of None (NFC)

This patch mechanically replaces None with std::nullopt where the
compiler would warn if None were deprecated.  The intent is to reduce
the amount of manual work required in migrating from Optional to
std::optional.

This is part of an effort to migrate from llvm::Optional to
std::optional:

https://discourse.llvm.org/t/deprecating-llvm-optional-x-hasvalue-getvalue-getvalueor/63716




More information about the All-commits mailing list