public:
ASTConsumer() : SemaConsumer(false) { }
- virtual ~ASTConsumer() {}
+ virtual ~ASTConsumer() = default;
/// Initialize - This is called to initialize the consumer, providing the
/// ASTContext.
class CanProxy : public CanProxyAdaptor<T> {
public:
/// \brief Build a NULL proxy.
- CanProxy() { }
+ CanProxy() = default;
/// \brief Build a proxy to the given canonical type.
CanProxy(CanQual<T> Stored) { this->Stored = Stored; }
CanQualType,
typename std::iterator_traits<InputIterator>::difference_type,
CanProxy<Type>, CanQualType> {
- CanTypeIterator() {}
+ CanTypeIterator() = default;
explicit CanTypeIterator(InputIterator Iter)
: CanTypeIterator::iterator_adaptor_base(std::move(Iter)) {}
friend class CXXRecordDecl;
explicit friend_iterator(FriendDecl *Ptr) : Ptr(Ptr) {}
public:
- friend_iterator() {}
+ friend_iterator() = default;
typedef FriendDecl *value_type;
typedef FriendDecl *reference;
typename std::iterator_traits<typename llvm::FoldingSetVector<
EntryType>::iterator>::iterator_category,
DeclType *, ptrdiff_t, DeclType *, DeclType *> {
- SpecIterator() {}
+ SpecIterator() = default;
explicit SpecIterator(
typename llvm::FoldingSetVector<EntryType>::iterator SetIter)
: SpecIterator::iterator_adaptor_base(std::move(SetIter)) {}
{}
public:
- Classification() {}
+ Classification() = default;
Kinds getKind() const { return static_cast<Kinds>(Kind); }
ModifiableType getModifiable() const {
friend class DesignatedInitExpr;
public:
- Designator() {}
+ Designator() = default;
/// @brief Initializes a field designator.
Designator(const IdentifierInfo *FieldName, SourceLocation DotLoc,
: Expr(ArrayTypeTraitExprClass, Empty), ATT(0), Value(false),
QueriedType() { }
- virtual ~ArrayTypeTraitExpr() { }
+ virtual ~ArrayTypeTraitExpr() = default;
SourceLocation getLocStart() const LLVM_READONLY { return Loc; }
SourceLocation getLocEnd() const LLVM_READONLY { return RParen; }
ManglerKind Kind)
: Context(Context), Diags(Diags), Kind(Kind) {}
- virtual ~MangleContext() { }
+ virtual ~MangleContext() = default;
ASTContext &getASTContext() const { return Context; }
/// literals within a particular context.
class MangleNumberingContext : public RefCountedBase<MangleNumberingContext> {
public:
- virtual ~MangleNumberingContext() {}
+ virtual ~MangleNumberingContext() = default;
/// \brief Retrieve the mangling number of a new lambda expression with the
/// given call operator within this context.
template<typename decl_type>
class Mergeable {
public:
- Mergeable() {}
+ Mergeable() = default;
/// \brief Return the first declaration of this declaration or itself if this
/// is the only declaration.
protected:
StmtIteratorImpl(const StmtIteratorBase& RHS) : StmtIteratorBase(RHS) {}
public:
- StmtIteratorImpl() {}
+ StmtIteratorImpl() = default;
StmtIteratorImpl(Stmt **s) : StmtIteratorBase(s) {}
StmtIteratorImpl(Decl **dgi, Decl **dge) : StmtIteratorBase(dgi, dge) {}
StmtIteratorImpl(const VariableArrayType *t) : StmtIteratorBase(t) {}
// UnresolvedSet.
private:
template <unsigned N> friend class UnresolvedSet;
- UnresolvedSetImpl() {}
+ UnresolvedSetImpl() = default;
UnresolvedSetImpl(const UnresolvedSetImpl &) {}
public:
bool isMicrosoft() const { return IsMicrosoftABI; }
- virtual ~VTableContextBase() {}
+ virtual ~VTableContextBase() = default;
protected:
typedef llvm::DenseMap<const CXXMethodDecl *, ThunkInfoVectorTy> ThunksMapTy;
/// BoundNodesTree.
class Visitor {
public:
- virtual ~Visitor() {}
+ virtual ~Visitor() = default;
/// \brief Called multiple times during a single call to VisitMatches(...).
///
template <typename T>
class MatcherInterface : public DynMatcherInterface {
public:
- ~MatcherInterface() override {}
+ ~MatcherInterface() override = default;
/// \brief Returns true if 'Node' can be matched.
///
AMM_ParentOnly
};
- virtual ~ASTMatchFinder() {}
+ virtual ~ASTMatchFinder() = default;
/// \brief Returns true if the given class is directly or indirectly derived
/// from a base type matching \c base.
BindableMatcher<SourceT>, Matcher<TargetT>,
makeDynCastAllOfComposite<SourceT, TargetT> > {
public:
- VariadicDynCastAllOfMatcher() {}
+ VariadicDynCastAllOfMatcher() = default;
};
/// \brief A \c VariadicAllOfMatcher<T> object is a variadic functor that takes
BindableMatcher<T>, Matcher<T>,
makeAllOfComposite<T> > {
public:
- VariadicAllOfMatcher() {}
+ VariadicAllOfMatcher() = default;
};
/// \brief Matches nodes of type \c TLoc for which the inner
struct Func : public llvm::VariadicFunction<Self, Matcher<InnerTBase>,
&Self::create> {
- Func() {}
+ Func() = default;
};
private:
class FormatStringHandler {
public:
- FormatStringHandler() {}
+ FormatStringHandler() = default;
virtual ~FormatStringHandler();
virtual void HandleNullChar(const char *nullCharacter) {}
class Observer {
virtual void anchor();
public:
- virtual ~Observer() {}
+ virtual ~Observer() = default;
/// A callback invoked right before invoking the
/// liveness transfer function on the given statement.
class Callback {
virtual void anchor();
public:
- virtual ~Callback() {}
+ virtual ~Callback() = default;
virtual void HandleUnreachable(UnreachableKind UK,
SourceLocation L,
SourceRange ConditionVal,
class VisitReducer : public Traversal<Self, VisitReducerBase>,
public VisitReducerBase {
public:
- VisitReducer() {}
+ VisitReducer() = default;
public:
R_SExpr reduceNull() { return true; }
class UninitVariablesHandler {
public:
- UninitVariablesHandler() {}
+ UninitVariablesHandler() = default;
virtual ~UninitVariablesHandler();
/// Called when the uninitialized variable is used at the given expression.
/// to AnalysisDeclContext.
class ManagedAnalysis {
protected:
- ManagedAnalysis() {}
+ ManagedAnalysis() = default;
public:
virtual ~ManagedAnalysis();
Block(blk), Index(idx) {}
public:
- ~StackFrameContext() override {}
+ ~StackFrameContext() override = default;
const Stmt *getCallSite() const { return CallSite; }
: LocationContext(Scope, ctx, parent), Enter(s) {}
public:
- ~ScopeContext() override {}
+ ~ScopeContext() override = default;
void Profile(llvm::FoldingSetNodeID &ID) override;
: LocationContext(Block, ctx, parent), BD(bd), ContextData(contextData) {}
public:
- ~BlockInvocationContext() override {}
+ ~BlockInvocationContext() override = default;
const BlockDecl *getBlockDecl() const { return BD; }
/// operator error is found when building the CFG.
class CFGCallback {
public:
- CFGCallback() {}
+ CFGCallback() = default;
virtual void compareAlwaysTrue(const BinaryOperator *B, bool isAlwaysTrue) {}
virtual void compareBitwiseEquality(const BinaryOperator *B,
bool isAlwaysTrue) {}
- virtual ~CFGCallback() {}
+ virtual ~CFGCallback() = default;
};
/// CFG - Represents a source-level, intra-procedural CFG that represents the
std::unique_ptr<FileSystemStatCache> NextStatCache;
public:
- virtual ~FileSystemStatCache() {}
+ virtual ~FileSystemStatCache() = default;
enum LookupResult {
CacheExists, ///< We know the file exists and its cached stat data.
void operator=(const IdentifierIterator &) = delete;
protected:
- IdentifierIterator() { }
+ IdentifierIterator() = default;
public:
virtual ~IdentifierIterator();
// FIXME: This really shouldn't be copyable, but is currently copied in some
// error handling in Driver::generateCompilationDiagnostics.
Command(const Command &) = default;
- virtual ~Command() {}
+ virtual ~Command() = default;
virtual void Print(llvm::raw_ostream &OS, const char *Terminator, bool Quote,
CrashReportInfo *CrashInfo = nullptr) const;
class EditsReceiver {
public:
- virtual ~EditsReceiver() { }
+ virtual ~EditsReceiver() = default;
virtual void insert(SourceLocation loc, StringRef text) = 0;
virtual void replace(CharSourceRange range, StringRef text) = 0;
/// the various constructs that are found in serialized diagnostics.
class SerializedDiagnosticReader {
public:
- SerializedDiagnosticReader() {}
- virtual ~SerializedDiagnosticReader() {}
+ SerializedDiagnosticReader() = default;
+ virtual ~SerializedDiagnosticReader() = default;
/// \brief Read the diagnostics in \c File
std::error_code readDiagnostics(StringRef File);
unsigned Min, Max;
bool MatchAnyLine;
- virtual ~Directive() { }
+ virtual ~Directive() = default;
// Returns true if directive text is valid.
// Otherwise returns false and populates E.
/// reads module map files.
class ModuleMapCallbacks {
public:
- virtual ~ModuleMapCallbacks() {}
+ virtual ~ModuleMapCallbacks() = default;
/// \brief Called when a module map file has been read.
///
PTHLexer(Preprocessor& pp, FileID FID, const unsigned char *D,
const unsigned char* ppcond, PTHManager &PM);
public:
- ~PTHLexer() override {}
+ ~PTHLexer() override = default;
/// Lex - Return the next token.
bool Lex(Token &Tok);
ParsingFilename(false),
LexingRawMode(false) {}
- virtual ~PreprocessorLexer() {}
+ virtual ~PreprocessorLexer() = default;
virtual void IndirectLex(Token& Result) = 0;
TypeDiagnoser(bool Suppressed = false) : Suppressed(Suppressed) { }
virtual void diagnose(Sema &S, SourceLocation Loc, QualType T) = 0;
- virtual ~TypeDiagnoser() {}
+ virtual ~TypeDiagnoser() = default;
};
static int getPrintable(int I) { return I; }
virtual SemaDiagnosticBuilder diagnoseConversion(
Sema &S, SourceLocation Loc, QualType T, QualType ConvTy) = 0;
- virtual ~ContextualImplicitConverter() {}
+ virtual ~ContextualImplicitConverter() = default;
};
class ICEConvertDiagnoser : public ContextualImplicitConverter {
virtual void diagnoseNotICE(Sema &S, SourceLocation Loc, SourceRange SR) =0;
virtual void diagnoseFold(Sema &S, SourceLocation Loc, SourceRange SR);
- virtual ~VerifyICEDiagnoser() { }
+ virtual ~VerifyICEDiagnoser() = default;
};
/// VerifyIntegerConstantExpression - Verifies that an expression is an ICE,
IsObjCIvarLookup(false), IsAddressOfOperand(false), Typo(Typo),
TypoNNS(TypoNNS) {}
- virtual ~CorrectionCandidateCallback() {}
+ virtual ~CorrectionCandidateCallback() = default;
/// \brief Simple predicate used by the default RankCandidate to
/// determine whether to return an edit distance of 0 or InvalidDistance.
class NodeResolver {
virtual void anchor();
public:
- virtual ~NodeResolver() {}
+ virtual ~NodeResolver() = default;
virtual const ExplodedNode*
getOriginalNode(const ExplodedNode *N) = 0;
};
public:
BugReporterContext(GRBugReporter& br) : BR(br) {}
- virtual ~BugReporterContext() {}
+ virtual ~BugReporterContext() = default;
GRBugReporter& getBugReporter() { return BR; }
BugType(const CheckerBase *checker, StringRef name, StringRef cat)
: Check(checker->getCheckName()), Name(name), Category(cat),
SuppressonSink(false) {}
- virtual ~BugType() {}
+ virtual ~BugType() = default;
// FIXME: Should these be made strings as well?
StringRef getName() const { return Name; }
public:
StackHintGeneratorForSymbol(SymbolRef S, StringRef M) : Sym(S), Msg(M) {}
- ~StackHintGeneratorForSymbol() override {}
+ ~StackHintGeneratorForSymbol() override = default;
/// \brief Search the call expression for the symbol Sym and dispatch the
/// 'getMessageForX()' methods to construct a specific message.
RegionAndSymbolInvalidationTraits *ETraits) const {}
public:
- virtual ~CallEvent() {}
+ virtual ~CallEvent() = default;
/// \brief Returns the kind of call this is.
virtual Kind getKind() const = 0;
assert(hasNoSinksInFrontier());
}
- virtual ~NodeBuilder() {}
+ virtual ~NodeBuilder() = default;
/// \brief Generates a node in the ExplodedGraph.
ExplodedNode *generateNode(const ProgramPoint &PP,
ArrayIndexTy(context.IntTy),
ArrayIndexWidth(context.getTypeSize(ArrayIndexTy)) {}
- virtual ~SValBuilder() {}
+ virtual ~SValBuilder() = default;
bool haveSameType(const SymExpr *Sym1, const SymExpr *Sym2) {
return haveSameType(Sym1->getType(), Sym2->getType());
StoreManager(ProgramStateManager &stateMgr);
public:
- virtual ~StoreManager() {}
+ virtual ~StoreManager() = default;
/// Return the value bound to specified location in a given state.
/// \param[in] store The analysis state.
class SubEngine {
virtual void anchor();
public:
- virtual ~SubEngine() {}
+ virtual ~SubEngine() = default;
virtual ProgramStateRef getInitialState(const LocationContext *InitLoc) = 0;
SymExpr(Kind k) : K(k) {}
public:
- virtual ~SymExpr() {}
+ virtual ~SymExpr() = default;
Kind getKind() const { return K; }
SymbolData(Kind k, SymbolID sym) : SymExpr(k), Sym(sym) {}
public:
- ~SymbolData() override {}
+ ~SymbolData() override = default;
SymbolID getSymbolID() const { return Sym; }
class TaintManager {
- TaintManager() {}
+ TaintManager() = default;
};
}
class Visitor {
public:
- Visitor() {}
+ Visitor() = default;
virtual ~Visitor();
virtual bool visit(const WorkListUnit &U) = 0;
};
namespace tooling {
struct PathComparator {
- virtual ~PathComparator() {}
+ virtual ~PathComparator() = default;
virtual bool equivalent(StringRef FileA, StringRef FileB) const = 0;
};
class FileMatchTrieNode;
/// newFrontendActionFactory.
class SourceFileCallbacks {
public:
- virtual ~SourceFileCallbacks() {}
+ virtual ~SourceFileCallbacks() = default;
/// \brief Called before a source file is processed by a FrontEndAction.
/// \see clang::FrontendAction::BeginSourceFileAction
} // end anonymous namespace.
/// \brief Anchor for VTable.
-MigrationProcess::RewriteListener::~RewriteListener() { }
+MigrationProcess::RewriteListener::~RewriteListener() = default;
MigrationProcess::MigrationProcess(
const CompilerInvocation &CI,
return PP.getLocForEndOfToken(loc);
}
-TransformActions::RewriteReceiver::~RewriteReceiver() { }
+TransformActions::RewriteReceiver::~RewriteReceiver() = default;
TransformActions::TransformActions(DiagnosticsEngine &diag,
CapturedDiagList &capturedDiags,
using namespace arcmt;
using namespace trans;
-ASTTraverser::~ASTTraverser() { }
+ASTTraverser::~ASTTraverser() = default;
bool MigrationPass::CFBridgingFunctionsDefined() {
if (!EnableCFBridgeFns.hasValue())
}
}
-ASTMutationListener::~ASTMutationListener() { }
+ASTMutationListener::~ASTMutationListener() = default;
void ASTMutationListener::DeducedReturnType(const FunctionDecl *FD,
QualType ReturnType) {}
llvm_unreachable("Unsupported ABI");
}
-CXXABI::~CXXABI() {}
+CXXABI::~CXXABI() = default;
size_t ASTContext::getSideTableAllocatedMemory() const {
return ASTRecordLayouts.getMemorySize() +
= ToContext.getTranslationUnitDecl();
}
-ASTImporter::~ASTImporter() { }
+ASTImporter::~ASTImporter() = default;
QualType ASTImporter::Import(QualType FromT) {
if (FromT.isNull())
//===----------------------------------------------------------------------===//
// Out-of-line virtual method providing a home for Decl.
-Decl::~Decl() { }
+Decl::~Decl() = default;
void Decl::setDeclContext(DeclContext *DC) {
DeclCtx = DC;
}
}
-DeclContext::~DeclContext() { }
+DeclContext::~DeclContext() = default;
/// \brief Find the parent context of this context that will be
/// used for unqualified name lookup.
using namespace clang;
-ExternalASTSource::~ExternalASTSource() { }
+ExternalASTSource::~ExternalASTSource() = default;
llvm::Optional<ExternalASTSource::ASTSourceDescriptor>
ExternalASTSource::getSourceDescriptor(unsigned ID) {
//===----------------------------------------------------------------------===//
// Implement virtual destructor.
-PrinterHelper::~PrinterHelper() {}
+PrinterHelper::~PrinterHelper() = default;
});
}
-VTableLayout::~VTableLayout() { }
+VTableLayout::~VTableLayout() = default;
ItaniumVTableContext::ItaniumVTableContext(ASTContext &Context)
: VTableContextBase(/*MS=*/false) {}
: Nodes(Nodes), Context(Context),
SourceManager(&Context->getSourceManager()) {}
-MatchFinder::MatchCallback::~MatchCallback() {}
-MatchFinder::ParsingDoneTestCallback::~ParsingDoneTestCallback() {}
+MatchFinder::MatchCallback::~MatchCallback() = default;
+MatchFinder::ParsingDoneTestCallback::~ParsingDoneTestCallback() = default;
MatchFinder::MatchFinder(MatchFinderOptions Options)
: Options(std::move(Options)), ParsingDone(nullptr) {}
-MatchFinder::~MatchFinder() {}
+MatchFinder::~MatchFinder() = default;
void MatchFinder::addMatcher(const DeclarationMatcher &NodeMatch,
MatchCallback *Action) {
/// arguments, and various other methods for type introspection.
class MatcherDescriptor {
public:
- virtual ~MatcherDescriptor() {}
+ virtual ~MatcherDescriptor() = default;
virtual VariantMatcher create(SourceRange NameRange,
ArrayRef<ParserValue> Args,
Diagnostics *Error) const = 0;
OverloadedMatcherDescriptor(ArrayRef<MatcherDescriptor *> Callbacks)
: Overloads(Callbacks.begin(), Callbacks.end()) {}
- ~OverloadedMatcherDescriptor() override {}
+ ~OverloadedMatcherDescriptor() override = default;
VariantMatcher create(SourceRange NameRange,
ArrayRef<ParserValue> Args,
const char *CodeCompletionLocation;
};
-Parser::Sema::~Sema() {}
+Parser::Sema::~Sema() = default;
std::vector<ArgKind> Parser::Sema::getAcceptedCompletionTypes(
llvm::ArrayRef<std::pair<MatcherCtor, unsigned>> Context) {
: Tokenizer(Tokenizer), S(S ? S : &*DefaultRegistrySema),
NamedValues(NamedValues), Error(Error) {}
-Parser::RegistrySema::~RegistrySema() {}
+Parser::RegistrySema::~RegistrySema() = default;
llvm::Optional<MatcherCtor>
Parser::RegistrySema::lookupMatcherCtor(StringRef MatcherName) {
return DynTypedMatcher::constructVariadic(Op, NodeKind, DynMatchers);
}
-VariantMatcher::Payload::~Payload() {}
+VariantMatcher::Payload::~Payload() = default;
class VariantMatcher::SinglePayload : public VariantMatcher::Payload {
public:
PolymorphicPayload(std::vector<DynTypedMatcher> MatchersIn)
: Matchers(std::move(MatchersIn)) {}
- ~PolymorphicPayload() override {}
+ ~PolymorphicPayload() override = default;
llvm::Optional<DynTypedMatcher> getSingleMatcher() const override {
if (Matchers.size() != 1)
// Cleanup.
//===----------------------------------------------------------------------===//
-ManagedAnalysis::~ManagedAnalysis() {}
+ManagedAnalysis::~ManagedAnalysis() = default;
AnalysisDeclContext::~AnalysisDeclContext() {
delete forcedBlkExprs;
llvm::DeleteContainerSeconds(Contexts);
}
-LocationContext::~LocationContext() {}
+LocationContext::~LocationContext() = default;
LocationContextManager::~LocationContextManager() {
clear();
}
}
- ~StmtPrinterHelper() override {}
+ ~StmtPrinterHelper() override = default;
const LangOptions &getLangOpts() const { return LangOpts; }
void setBlockID(signed i) { currentBlock = i; }
using namespace clang;
-CodeInjector::CodeInjector() {}
-CodeInjector::~CodeInjector() {}
+CodeInjector::CodeInjector() = default;
+CodeInjector::~CodeInjector() = default;
using namespace consumed;
// Key method definition
-ConsumedWarningsHandlerBase::~ConsumedWarningsHandlerBase() {}
+ConsumedWarningsHandlerBase::~ConsumedWarningsHandlerBase() = default;
static SourceLocation getFirstStmtLoc(const CFGBlock *Block) {
// Find the source location of the first statement in the block, if the block
using namespace clang;
// Key function to FormatStringHandler.
-FormatStringHandler::~FormatStringHandler() {}
+FormatStringHandler::~FormatStringHandler() = default;
//===----------------------------------------------------------------------===//
// Functions for parsing format strings components in both printf and
using namespace clang;
-ProgramPointTag::~ProgramPointTag() {}
+ProgramPointTag::~ProgramPointTag() = default;
ProgramPoint ProgramPoint::getProgramPoint(const Stmt *S, ProgramPoint::Kind K,
const LocationContext *LC,
using namespace threadSafety;
// Key method definition
-ThreadSafetyHandler::~ThreadSafetyHandler() {}
+ThreadSafetyHandler::~ThreadSafetyHandler() = default;
namespace {
class TILPrinter :
: CapabilityExpr(CE), LKind(LK), AcquireLoc(Loc), Asserted(Asrt),
Declared(Declrd) {}
- virtual ~FactEntry() {}
+ virtual ~FactEntry() = default;
LockKind kind() const { return LKind; }
SourceLocation loc() const { return AcquireLoc; }
: hadUse(numBlocks, false), hadAnyUse(false),
currentBlock(0) {}
- ~PruneBlocksHandler() override {}
+ ~PruneBlocksHandler() override = default;
/// Records if a CFGBlock had a potential use of an uninitialized variable.
llvm::BitVector hadUse;
}
}
-UninitVariablesHandler::~UninitVariablesHandler() {}
+UninitVariablesHandler::~UninitVariablesHandler() = default;
}
-DiagnosticConsumer::~DiagnosticConsumer() {}
+DiagnosticConsumer::~DiagnosticConsumer() = default;
void DiagnosticConsumer::HandleDiagnostic(DiagnosticsEngine::Level DiagLevel,
const Diagnostic &Info) {
void IgnoringDiagConsumer::anchor() { }
-ForwardingDiagnosticConsumer::~ForwardingDiagnosticConsumer() {}
+ForwardingDiagnosticConsumer::~ForwardingDiagnosticConsumer() = default;
void ForwardingDiagnosticConsumer::HandleDiagnostic(
DiagnosticsEngine::Level DiagLevel,
}
// Virtual destructors for abstract base classes that need live in Basic.
-PCHContainerWriter::~PCHContainerWriter() {}
-PCHContainerReader::~PCHContainerReader() {}
+PCHContainerWriter::~PCHContainerWriter() = default;
+PCHContainerReader::~PCHContainerReader() = default;
// IdentifierTable Implementation
//===----------------------------------------------------------------------===//
-IdentifierIterator::~IdentifierIterator() { }
+IdentifierIterator::~IdentifierIterator() = default;
-IdentifierInfoLookup::~IdentifierInfoLookup() {}
+IdentifierInfoLookup::~IdentifierInfoLookup() = default;
namespace {
/// \brief A simple identifier lookup iterator that represents an
}
}
-ExternalSLocEntrySource::~ExternalSLocEntrySource() { }
+ExternalSLocEntrySource::~ExternalSLocEntrySource() = default;
/// Return the amount of memory used by memory buffers, breaking down
/// by heap-backed versus mmap'ed memory.
}
// Out of line virtual dtor for TargetInfo.
-TargetInfo::~TargetInfo() {}
+TargetInfo::~TargetInfo() = default;
/// getTypeName - Return the user string for the specified integer type enum.
/// For example, SignedShort -> "short".
return isStatusKnown() && Type != file_type::file_not_found;
}
-File::~File() {}
+File::~File() = default;
-FileSystem::~FileSystem() {}
+FileSystem::~FileSystem() = default;
ErrorOr<std::unique_ptr<MemoryBuffer>>
FileSystem::getBufferForFile(const llvm::Twine &Name, int64_t FileSize,
return std::error_code();
}
-clang::vfs::detail::DirIterImpl::~DirIterImpl() { }
+clang::vfs::detail::DirIterImpl::~DirIterImpl() = default;
namespace {
class OverlayFSDirIterImpl : public clang::vfs::detail::DirIterImpl {
public:
InMemoryNode(Status Stat, InMemoryNodeKind Kind)
: Stat(std::move(Stat)), Kind(Kind) {}
- virtual ~InMemoryNode() {}
+ virtual ~InMemoryNode() = default;
const Status &getStatus() const { return Stat; }
InMemoryNodeKind getKind() const { return Kind; }
virtual std::string toString(unsigned Indent) const = 0;
llvm::sys::fs::perms::all_all))),
UseNormalizedPaths(UseNormalizedPaths) {}
-InMemoryFileSystem::~InMemoryFileSystem() {}
+InMemoryFileSystem::~InMemoryFileSystem() = default;
std::string InMemoryFileSystem::toString() const {
return Root->toString(/*Indent=*/0);
}
// Anchor the vtable to this translation unit.
-BlockByrefHelpers::~BlockByrefHelpers() {}
+BlockByrefHelpers::~BlockByrefHelpers() = default;
/// Build the given block as a global block.
static llvm::Constant *buildGlobalBlock(CodeGenModule &CGM,
using namespace clang;
using namespace CodeGen;
-CGCUDARuntime::~CGCUDARuntime() {}
+CGCUDARuntime::~CGCUDARuntime() = default;
RValue CGCUDARuntime::EmitCUDAKernelCallExpr(CodeGenFunction &CGF,
const CUDAKernelCallExpr *E,
using namespace clang;
using namespace CodeGen;
-CGCXXABI::~CGCXXABI() { }
+CGCXXABI::~CGCXXABI() = default;
void CGCXXABI::ErrorUnsupportedABI(CodeGenFunction &CGF, StringRef S) {
DiagnosticsEngine &Diags = CGF.CGM.getDiags();
const TypeExpansionKind Kind;
TypeExpansion(TypeExpansionKind K) : Kind(K) {}
- virtual ~TypeExpansion() {}
+ virtual ~TypeExpansion() = default;
};
struct ConstantArrayExpansion : TypeExpansion {
}
-CGObjCRuntime::~CGObjCRuntime() {}
+CGObjCRuntime::~CGObjCRuntime() = default;
using namespace clang;
using namespace CodeGen;
-CGOpenCLRuntime::~CGOpenCLRuntime() {}
+CGOpenCLRuntime::~CGOpenCLRuntime() = default;
void CGOpenCLRuntime::EmitWorkGroupLocalVarDecl(CodeGenFunction &CGF,
const VarDecl &D) {
public:
explicit CGOpenMPRuntime(CodeGenModule &CGM);
- virtual ~CGOpenMPRuntime() {}
+ virtual ~CGOpenMPRuntime() = default;
virtual void clear();
/// \brief Emits outlined function for the specified OpenMP parallel directive
return Address(V, Addr.getAlignment());
}
-CodeGenFunction::CGCapturedStmtInfo::~CGCapturedStmtInfo() { }
+CodeGenFunction::CGCapturedStmtInfo::~CGCapturedStmtInfo() = default;
CodeGenFunction::SanitizerScope::SanitizerScope(CodeGenFunction *CGF)
: CGF(CGF) {
MDHelper(VMContext), Root(nullptr), Char(nullptr) {
}
-CodeGenTBAA::~CodeGenTBAA() {
-}
+CodeGenTBAA::~CodeGenTBAA() = default;
llvm::MDNode *CodeGenTBAA::getRoot() {
// Define the root of the tree. This identifies the tree, so that
return Address::invalid();
}
-ABIInfo::~ABIInfo() {}
+ABIInfo::~ABIInfo() = default;
static CGCXXABI::RecordArgABI getRecordArgABI(const RecordType *RT,
CGCXXABI &CXXABI) {
ResponseSupport(_ResponseSupport), ResponseEncoding(_ResponseEncoding),
ResponseFlag(_ResponseFlag) {}
-Tool::~Tool() {
-}
+Tool::~Tool() = default;
<< A->getValue() << A->getAsString(Args);
}
-ToolChain::~ToolChain() {
-}
+ToolChain::~ToolChain() = default;
vfs::FileSystem &ToolChain::getVFS() const { return getDriver().getVFS(); }
}
}
-Darwin::~Darwin() {}
+Darwin::~Darwin() = default;
-MachO::~MachO() {}
+MachO::~MachO() = default;
std::string MachO::ComputeEffectiveClangTriple(const ArgList &Args,
types::ID InputType) const {
getProgramPaths().push_back(getDriver().Dir);
}
-Generic_GCC::~Generic_GCC() {}
+Generic_GCC::~Generic_GCC() = default;
Tool *Generic_GCC::getTool(Action::ActionClass AC) const {
switch (AC) {
GetTargetCPU(Args), InstalledDir, LibPaths);
}
-HexagonToolChain::~HexagonToolChain() {}
+HexagonToolChain::~HexagonToolChain() = default;
Tool *HexagonToolChain::buildAssembler() const {
return new tools::hexagon::Assembler(*this);
getProgramPaths().push_back(Path);
}
-TCEToolChain::~TCEToolChain() {}
+TCEToolChain::~TCEToolChain() = default;
bool TCEToolChain::IsMathErrnoDefault() const { return true; }
}
}
-MyriadToolChain::~MyriadToolChain() {}
+MyriadToolChain::~MyriadToolChain() = default;
void MyriadToolChain::AddClangSystemIncludeArgs(const ArgList &DriverArgs,
ArgStringList &CC1Args) const {
/// \brief Contains starting character index and length of split.
typedef std::pair<StringRef::size_type, unsigned> Split;
- virtual ~BreakableToken() {}
+ virtual ~BreakableToken() = default;
/// \brief Returns the number of lines in this token in the original code.
virtual unsigned getLineCount() const = 0;
}
}
-TokenRole::~TokenRole() {}
+TokenRole::~TokenRole() = default;
void TokenRole::precomputeFormattingInfos(const FormatToken *Token) {}
UnwrappedLineFormatter *BlockFormatter)
: Indenter(Indenter), Whitespaces(Whitespaces), Style(Style),
BlockFormatter(BlockFormatter) {}
- virtual ~LineFormatter() {}
+ virtual ~LineFormatter() = default;
/// \brief Formats an \c AnnotatedLine and returns the penalty.
///
class FormatTokenSource {
public:
- virtual ~FormatTokenSource() {}
+ virtual ~FormatTokenSource() = default;
virtual FormatToken *getNextToken() = 0;
virtual unsigned getPosition() = 0;
class UnwrappedLineConsumer {
public:
- virtual ~UnwrappedLineConsumer() {}
+ virtual ~UnwrappedLineConsumer() = default;
virtual void consumeUnwrappedLine(const UnwrappedLine &Line) = 0;
virtual void finishRun() = 0;
};
#else // NDEBUG
ASTUnit::ConcurrencyState::ConcurrencyState() { Mutex = nullptr; }
-ASTUnit::ConcurrencyState::~ConcurrencyState() {}
+ASTUnit::ConcurrencyState::~ConcurrencyState() = default;
void ASTUnit::ConcurrencyState::start() {}
void ASTUnit::ConcurrencyState::finish() {}
Offset TokenData, PPCondData;
public:
- PTHEntry() {}
+ PTHEntry() = default;
PTHEntry(Offset td, Offset ppcd)
: TokenData(td), PPCondData(ppcd) {}
PTHMap &PM;
public:
StatListener(PTHMap &pm) : PM(pm) {}
- ~StatListener() override {}
+ ~StatListener() override = default;
LookupResult getStat(const char *Path, FileData &Data, bool isFile,
std::unique_ptr<vfs::File> *F,
HeaderSearchOpts(new HeaderSearchOptions(X.getHeaderSearchOpts())),
PreprocessorOpts(new PreprocessorOptions(X.getPreprocessorOpts())) {}
-CompilerInvocationBase::~CompilerInvocationBase() {}
+CompilerInvocationBase::~CompilerInvocationBase() = default;
//===----------------------------------------------------------------------===//
// Deserialization (from args)
(needSystemDependencies() || !IsSystem);
}
-DependencyCollector::~DependencyCollector() { }
+DependencyCollector::~DependencyCollector() = default;
void DependencyCollector::attachToPreprocessor(Preprocessor &PP) {
PP.addPPCallbacks(
llvm::make_unique<DepCollectorPPCallbacks>(*this, PP.getSourceManager()));
DiagnosticOptions *DiagOpts)
: LangOpts(LangOpts), DiagOpts(DiagOpts), LastLevel() {}
-DiagnosticRenderer::~DiagnosticRenderer() {}
+DiagnosticRenderer::~DiagnosticRenderer() = default;
namespace {
emitSingleMacroExpansion(*I, Level, Ranges, SM);
}
-DiagnosticNoteRenderer::~DiagnosticNoteRenderer() {}
+DiagnosticNoteRenderer::~DiagnosticNoteRenderer() = default;
void DiagnosticNoteRenderer::emitIncludeLocation(SourceLocation Loc,
PresumedLoc PLoc,
FrontendAction::FrontendAction() : Instance(nullptr) {}
-FrontendAction::~FrontendAction() {}
+FrontendAction::~FrontendAction() = default;
void FrontendAction::setCurrentInput(const FrontendInputFile &CurrentInput,
std::unique_ptr<ASTUnit> AST) {
}
}
-MultiplexConsumer::~MultiplexConsumer() {}
+MultiplexConsumer::~MultiplexConsumer() = default;
void MultiplexConsumer::Initialize(ASTContext &Context) {
for (auto &Consumer : Consumers)
Diags.setClient(this, false);
}
-FixItOptions::~FixItOptions() {}
+FixItOptions::~FixItOptions() = default;
}
FixItAction::FixItAction() {}
-FixItAction::~FixItAction() {}
+FixItAction::~FixItAction() = default;
std::unique_ptr<ASTConsumer>
FixItAction::CreateASTConsumer(CompilerInstance &CI, StringRef InFile) {
DiagnosticsEngine &D, const LangOptions &LOpts,
bool silenceMacroWarn, bool LineInfo);
- ~RewriteModernObjC() override {}
+ ~RewriteModernObjC() override = default;
void HandleTranslationUnit(ASTContext &C) override;
DiagnosticsEngine &D, const LangOptions &LOpts,
bool silenceMacroWarn);
- ~RewriteObjC() override {}
+ ~RewriteObjC() override = default;
void HandleTranslationUnit(ASTContext &C) override;
D, LOpts,
silenceMacroWarn) {}
- ~RewriteObjCFragileABI() override {}
+ ~RewriteObjCFragileABI() override = default;
void Initialize(ASTContext &context) override;
// Rewriting metadata
DiagnosticOptions *DiagOpts)
: DiagnosticNoteRenderer(LangOpts, DiagOpts), Writer(Writer) {}
- ~SDiagsRenderer() override {}
+ ~SDiagsRenderer() override = default;
protected:
void emitDiagnosticMessage(SourceLocation Loc,
EmitPreamble();
}
- ~SDiagsWriter() override {}
+ ~SDiagsWriter() override = default;
void HandleDiagnostic(DiagnosticsEngine::Level DiagLevel,
const Diagnostic &Info) override;
DiagnosticOptions *DiagOpts)
: DiagnosticRenderer(LangOpts, DiagOpts), OS(OS) {}
-TextDiagnostic::~TextDiagnostic() {}
+TextDiagnostic::~TextDiagnostic() = default;
void
TextDiagnostic::emitDiagnosticMessage(SourceLocation Loc,
}
CommentToXMLConverter::CommentToXMLConverter() : FormatInMemoryUniqueId(0) {}
-CommentToXMLConverter::~CommentToXMLConverter() {}
+CommentToXMLConverter::~CommentToXMLConverter() = default;
void CommentToXMLConverter::convertCommentToHTML(const FullComment *FC,
SmallVectorImpl<char> &HTML,
return ControllingMacro;
}
-ExternalHeaderFileInfoSource::~ExternalHeaderFileInfoSource() {}
+ExternalHeaderFileInfoSource::~ExternalHeaderFileInfoSource() = default;
HeaderSearch::HeaderSearch(IntrusiveRefCntPtr<HeaderSearchOptions> HSOpts,
SourceManager &SourceMgr, DiagnosticsEngine &Diags,
#include "llvm/Support/Path.h"
using namespace clang;
-PPCallbacks::~PPCallbacks() {}
+PPCallbacks::~PPCallbacks() = default;
//===----------------------------------------------------------------------===//
// Miscellaneous Methods.
StringIdLookup(std::move(stringIdLookup)), NumIds(numIds), PP(nullptr),
SpellingBase(spellingBase), OriginalSourceFile(originalSourceFile) {}
-PTHManager::~PTHManager() {
-}
+PTHManager::~PTHManager() = default;
static void InvalidPTH(DiagnosticsEngine &Diags, const char *Msg) {
Diags.Report(Diags.getCustomDiagID(DiagnosticsEngine::Error, "%0")) << Msg;
#include "llvm/Support/raw_ostream.h"
// Out-of-line destructor to provide a home for the class.
-PragmaHandler::~PragmaHandler() {
-}
+PragmaHandler::~PragmaHandler() = default;
//===----------------------------------------------------------------------===//
// EmptyPragmaHandler Implementation.
using namespace clang;
-ExternalPreprocessingRecordSource::~ExternalPreprocessingRecordSource() { }
+ExternalPreprocessingRecordSource::~ExternalPreprocessingRecordSource() = default;
InclusionDirective::InclusionDirective(PreprocessingRecord &PPRec,
using namespace clang;
//===----------------------------------------------------------------------===//
-ExternalPreprocessorSource::~ExternalPreprocessorSource() { }
+ExternalPreprocessorSource::~ExternalPreprocessorSource() = default;
Preprocessor::Preprocessor(IntrusiveRefCntPtr<PreprocessorOptions> PPOpts,
DiagnosticsEngine &diags, LangOptions &opts,
return true;
}
-ModuleLoader::~ModuleLoader() { }
+ModuleLoader::~ModuleLoader() = default;
-CommentHandler::~CommentHandler() { }
+CommentHandler::~CommentHandler() = default;
-CodeCompletionHandler::~CodeCompletionHandler() { }
+CodeCompletionHandler::~CodeCompletionHandler() = default;
void Preprocessor::createPreprocessingRecord() {
if (Record)
Toks.push_back(Eof);
}
-Parser::LateParsedDeclaration::~LateParsedDeclaration() {}
+Parser::LateParsedDeclaration::~LateParsedDeclaration() = default;
void Parser::LateParsedDeclaration::ParseLexedMethodDeclarations() {}
void Parser::LateParsedDeclaration::ParseLexedMemberInitializers() {}
void Parser::LateParsedDeclaration::ParseLexedMethodDefs() {}
}
}
-TokenRewriter::~TokenRewriter() {
-}
+TokenRewriter::~TokenRewriter() = default;
/// RemapIterator - Convert from token_iterator (a const iterator) to
// Go ahead and configure all the inline capacity. This is just a memset.
FreeLists.resize(InlineFreeListsCapacity);
}
-AttributeFactory::~AttributeFactory() {}
+AttributeFactory::~AttributeFactory() = default;
static size_t getFreeListIndexForSize(size_t size) {
assert(size >= sizeof(AttributeList));
// Code completion consumer implementation
//===----------------------------------------------------------------------===//
-CodeCompleteConsumer::~CodeCompleteConsumer() { }
+CodeCompleteConsumer::~CodeCompleteConsumer() = default;
void
PrintingCodeCompleteConsumer::ProcessCodeCompleteResults(Sema &SemaRef,
}
// pin the vtable here.
-MultiplexExternalSemaSource::~MultiplexExternalSemaSource() {}
+MultiplexExternalSemaSource::~MultiplexExternalSemaSource() = default;
///\brief Appends new source to the source list.
///
assert(VD);
}
-FunctionScopeInfo::~FunctionScopeInfo() { }
-BlockScopeInfo::~BlockScopeInfo() { }
-CapturedRegionScopeInfo::~CapturedRegionScopeInfo() { }
+FunctionScopeInfo::~FunctionScopeInfo() = default;
+BlockScopeInfo::~BlockScopeInfo() = default;
+CapturedRegionScopeInfo::~CapturedRegionScopeInfo() = default;
}
// Pin this vtable to this file.
-ExternalSemaSource::~ExternalSemaSource() {}
+ExternalSemaSource::~ExternalSemaSource() = default;
void ExternalSemaSource::ReadMethodPool(Selector Sel) { }
}
public:
- ExprBuilder() {}
- virtual ~ExprBuilder() {}
+ ExprBuilder() = default;
+ virtual ~ExprBuilder() = default;
virtual Expr *build(Sema &S, SourceLocation Loc) const = 0;
};
//----------------------------------------------------------------------------
// Search for all visible declarations.
//----------------------------------------------------------------------------
-VisibleDeclConsumer::~VisibleDeclConsumer() { }
+VisibleDeclConsumer::~VisibleDeclConsumer() = default;
bool VisibleDeclConsumer::includeHiddenDecls() const { return false; }
ArrayRef<T> Arr;
};
struct MatchesAlways {
- MatchesAlways() {}
+ MatchesAlways() = default;
template <class T> bool operator()(T) { return true; }
};
: S(S), ResultIndex(PseudoObjectExpr::NoResult),
GenericLoc(genericLoc) {}
- virtual ~PseudoOpBuilder() {}
+ virtual ~PseudoOpBuilder() = default;
/// Add a normal semantic expression.
void addSemanticExpr(Expr *semantic) {
const TemplateArgumentLoc *operator->() const { return &Arg; }
};
- TemplateArgumentLocInventIterator() { }
+ TemplateArgumentLocInventIterator() = default;
explicit TemplateArgumentLocInventIterator(TreeTransform<Derived> &Self,
InputIterator Iter)
};
- TemplateArgumentLocContainerIterator() {}
+ TemplateArgumentLocContainerIterator() = default;
TemplateArgumentLocContainerIterator(ArgLocContainer &Container,
unsigned Index)
using namespace clang;
// Give ASTDeserializationListener's VTable a home.
-ASTDeserializationListener::~ASTDeserializationListener() { }
+ASTDeserializationListener::~ASTDeserializationListener() = default;
serialization::TypeIdx
serialization::TypeIdxFromBuiltin(const BuiltinType *BT) {
// PCH validator implementation
//===----------------------------------------------------------------------===//
-ASTReaderListener::~ASTReaderListener() {}
+ASTReaderListener::~ASTReaderListener() = default;
/// \brief Compare the given set of language options against an existing set of
/// language options.
Buffer->IsComplete = false;
}
-PCHGenerator::~PCHGenerator() {
-}
+PCHGenerator::~PCHGenerator() = default;
void PCHGenerator::HandleTranslationUnit(ASTContext &Ctx) {
// Don't create a PCH if there were fatal failures during module loading.
friend class MultiOnDiskHashTableGenerator;
public:
- MultiOnDiskHashTable() {}
+ MultiOnDiskHashTable() = default;
MultiOnDiskHashTable(MultiOnDiskHashTable &&O)
: Tables(std::move(O.Tables)),
PendingOverrides(std::move(O.PendingOverrides)) {
: cfg(cfg), Ctx(ctx), BR(br), Checker(checker), AC(ac), Parents(parents),
Escaped(escaped), currentBlock(nullptr) {}
- ~DeadStoreObs() override {}
+ ~DeadStoreObs() override = default;
bool isLive(const LiveVariables::LivenessValues &Live, const VarDecl *D) {
if (Live.isLive(D))
"The maximum number of bug reports in the same equivalence class "
"where at least one report is valid (not suppressed)");
-BugReporterVisitor::~BugReporterVisitor() {}
+BugReporterVisitor::~BugReporterVisitor() = default;
void BugReporterContext::anchor() {}
// Methods for BugReporter and subclasses.
//===----------------------------------------------------------------------===//
-BugReportEquivClass::~BugReportEquivClass() { }
-GRBugReporter::~GRBugReporter() { }
-BugReporterData::~BugReporterData() {}
+BugReportEquivClass::~BugReportEquivClass() = default;
+GRBugReporter::~GRBugReporter() = default;
+BugReporterData::~BugReporterData() = default;
ExplodedGraph &GRBugReporter::getGraph() { return Eng.getGraph(); }
using namespace clang;
using namespace ento;
-ConstraintManager::~ConstraintManager() {}
+ConstraintManager::~ConstraintManager() = default;
static DefinedSVal getLocFromSymbol(const ProgramStateRef &State,
SymbolRef Sym) {
// Worklist classes for exploration of reachable states.
//===----------------------------------------------------------------------===//
-WorkList::Visitor::~Visitor() {}
+WorkList::Visitor::~Visitor() = default;
namespace {
class DFS : public WorkList {
// Place the dstor for WorkList here because it contains virtual member
// functions, and we the code for the dstor generated in one compilation unit.
-WorkList::~WorkList() {}
+WorkList::~WorkList() = default;
WorkList *WorkList::makeDFS() { return new DFS(); }
WorkList *WorkList::makeBFS() { return new BFS(); }
//===----------------------------------------------------------------------===//
// An out of line virtual method to provide a home for the class vtable.
-ExplodedNode::Auditor::~Auditor() {}
+ExplodedNode::Auditor::~Auditor() = default;
#ifndef NDEBUG
static ExplodedNode::Auditor* NodeAuditor = nullptr;
ExplodedGraph::ExplodedGraph()
: NumNodes(0), ReclaimNodeInterval(0) {}
-ExplodedGraph::~ExplodedGraph() {}
+ExplodedGraph::~ExplodedGraph() = default;
//===----------------------------------------------------------------------===//
// Node reclamation.
// Object destruction.
//===----------------------------------------------------------------------===//
-MemRegion::~MemRegion() {}
+MemRegion::~MemRegion() = default;
-MemRegionManager::~MemRegionManager() {
- // All regions and their data are BumpPtrAllocated. No need to call
- // their destructors.
-}
+// All regions and their data are BumpPtrAllocated. No need to call their
+// destructors.
+MemRegionManager::~MemRegionManager() = default;
//===----------------------------------------------------------------------===//
// Basic methods.
PathDiagnosticPiece::PathDiagnosticPiece(Kind k, DisplayHint hint)
: kind(k), Hint(hint), LastInMainSourceFile(false) {}
-PathDiagnosticPiece::~PathDiagnosticPiece() {}
-PathDiagnosticEventPiece::~PathDiagnosticEventPiece() {}
-PathDiagnosticCallPiece::~PathDiagnosticCallPiece() {}
-PathDiagnosticControlFlowPiece::~PathDiagnosticControlFlowPiece() {}
-PathDiagnosticMacroPiece::~PathDiagnosticMacroPiece() {}
+PathDiagnosticPiece::~PathDiagnosticPiece() = default;
+PathDiagnosticEventPiece::~PathDiagnosticEventPiece() = default;
+PathDiagnosticCallPiece::~PathDiagnosticCallPiece() = default;
+PathDiagnosticControlFlowPiece::~PathDiagnosticControlFlowPiece() = default;
+PathDiagnosticMacroPiece::~PathDiagnosticMacroPiece() = default;
void PathPieces::flattenTo(PathPieces &Primary, PathPieces &Current,
}
-PathDiagnostic::~PathDiagnostic() {}
+PathDiagnostic::~PathDiagnostic() = default;
PathDiagnostic::PathDiagnostic(StringRef CheckName, const Decl *declWithIssue,
StringRef bugtype, StringRef verboseDesc,
ID.AddString(*I);
}
-StackHintGenerator::~StackHintGenerator() {}
+StackHintGenerator::~StackHintGenerator() = default;
std::string StackHintGeneratorForSymbol::getMessage(const ExplodedNode *N){
ProgramPoint P = N->getLocation();
const LangOptions &LangOpts,
bool supportsMultipleFiles);
- ~PlistDiagnostics() override {}
+ ~PlistDiagnostics() override = default;
void FlushDiagnosticsImpl(std::vector<const PathDiagnostic *> &Diags,
FilesMade *filesMade) override;
namespace ento {
-SimpleConstraintManager::~SimpleConstraintManager() {}
+SimpleConstraintManager::~SimpleConstraintManager() = default;
bool SimpleConstraintManager::canReasonAbout(SVal X) const {
Optional<nonloc::SymbolVal> SymVal = X.getAs<nonloc::SymbolVal>();
SimpleSValBuilder(llvm::BumpPtrAllocator &alloc, ASTContext &context,
ProgramStateManager &stateMgr)
: SValBuilder(alloc, context, stateMgr) {}
- ~SimpleSValBuilder() override {}
+ ~SimpleSValBuilder() override = default;
SVal evalMinus(NonLoc val) override;
SVal evalComplement(NonLoc val) override;
Ctx));
}
-StoreManager::BindingsHandler::~BindingsHandler() {}
+StoreManager::BindingsHandler::~BindingsHandler() = default;
bool StoreManager::FindUniqueBinding::HandleBinding(StoreManager& SMgr,
Store store,
public:
ClangDiagPathDiagConsumer(DiagnosticsEngine &Diag)
: Diag(Diag), IncludePath(false) {}
- ~ClangDiagPathDiagConsumer() override {}
+ ~ClangDiagPathDiagConsumer() override = default;
StringRef getName() const override { return "ClangDiags"; }
bool supportsLogicalOpControlFlow() const override { return true; }
using namespace clang;
using namespace tooling;
-CompilationDatabase::~CompilationDatabase() {}
+CompilationDatabase::~CompilationDatabase() = default;
std::unique_ptr<CompilationDatabase>
CompilationDatabase::loadFromDirectory(StringRef BuildDirectory,
return DB;
}
-CompilationDatabasePlugin::~CompilationDatabasePlugin() {}
+CompilationDatabasePlugin::~CompilationDatabasePlugin() = default;
namespace {
// Helper for recursively searching through a chain of actions and collecting
namespace clang {
namespace tooling {
-ToolAction::~ToolAction() {}
+ToolAction::~ToolAction() = default;
-FrontendActionFactory::~FrontendActionFactory() {}
+FrontendActionFactory::~FrontendActionFactory() = default;
// FIXME: This file contains structural duplication with other parts of the
// code that sets up a compiler to run tools on it, and we should refactor
appendArgumentsAdjuster(getClangSyntaxOnlyAdjuster());
}
-ClangTool::~ClangTool() {}
+ClangTool::~ClangTool() = default;
void ClangTool::mapVirtualFile(StringRef FilePath, StringRef Content) {
MappedFileContents.push_back(std::make_pair(FilePath, Content));
llvm::StringRef toolDesc)
: cmd(toolCmd), description(toolDesc) {}
-DiagTool::~DiagTool() {}
+DiagTool::~DiagTool() = default;
typedef llvm::StringMap<DiagTool *> ToolMap;
static inline ToolMap *getTools(void *v) { return static_cast<ToolMap*>(v); }
using namespace clang::cxdiag;
using namespace llvm;
-CXDiagnosticSetImpl::~CXDiagnosticSetImpl() {}
+CXDiagnosticSetImpl::~CXDiagnosticSetImpl() = default;
void
CXDiagnosticSetImpl::appendDiagnostic(std::unique_ptr<CXDiagnosticImpl> D) {
Diagnostics.push_back(std::move(D));
}
-CXDiagnosticImpl::~CXDiagnosticImpl() {}
+CXDiagnosticImpl::~CXDiagnosticImpl() = default;
namespace {
class CXDiagnosticCustomNoteImpl : public CXDiagnosticImpl {
: CXDiagnosticImpl(CustomNoteDiagnosticKind),
Message(Msg), Loc(L) {}
- ~CXDiagnosticCustomNoteImpl() override {}
+ ~CXDiagnosticCustomNoteImpl() override = default;
CXDiagnosticSeverity getSeverity() const override {
return CXDiagnostic_Note;
: DiagnosticNoteRenderer(LangOpts, DiagOpts),
CurrentSet(mainSet), MainSet(mainSet) {}
- ~CXDiagnosticRenderer() override {}
+ ~CXDiagnosticRenderer() override = default;
void beginDiagnostic(DiagOrStoredDiag D,
DiagnosticsEngine::Level Level) override {
: CXDiagnosticImpl(StoredDiagnosticKind),
Diag(Diag), LangOpts(LangOpts) { }
- ~CXStoredDiagnostic() override {}
+ ~CXStoredDiagnostic() override = default;
/// \brief Return the severity of the diagnostic.
CXDiagnosticSeverity getSeverity() const override;
class CXLoadedDiagnosticSetImpl : public CXDiagnosticSetImpl {
public:
CXLoadedDiagnosticSetImpl() : CXDiagnosticSetImpl(true), FakeFiles(FO) {}
- ~CXLoadedDiagnosticSetImpl() override {}
+ ~CXLoadedDiagnosticSetImpl() override = default;
llvm::BumpPtrAllocator Alloc;
Strings Categories;
// Cleanup.
//===----------------------------------------------------------------------===//
-CXLoadedDiagnostic::~CXLoadedDiagnostic() {}
+CXLoadedDiagnostic::~CXLoadedDiagnostic() = default;
//===----------------------------------------------------------------------===//
// Public CXLoadedDiagnostic methods.
public:
SessionSkipBodyData() : Mux(/*recursive=*/false) {}
- ~SessionSkipBodyData() {
- //llvm::errs() << "RegionData: " << Skipped.size() << " - " << Skipped.getMemorySize() << "\n";
- }
+ ~SessionSkipBodyData() = default;
void copyTo(PPRegionSetTy &Set) {
llvm::MutexGuard MG(Mux);
private:
class Consumer : public clang::ASTConsumer {
public:
- ~Consumer() override {}
+ ~Consumer() override = default;
void HandleTranslationUnit(clang::ASTContext &Ctx) override {
VarInfoMap VarInfo;
class BoundNodesCallback {
public:
- virtual ~BoundNodesCallback() {}
+ virtual ~BoundNodesCallback() = default;
virtual bool run(const BoundNodes *BoundNodes) = 0;
virtual bool run(const BoundNodes *BoundNodes, ASTContext *Context) = 0;
virtual void onEndOfTranslationUnit() {}
class MockSema : public Parser::Sema {
public:
- ~MockSema() override {}
+ ~MockSema() override = default;
uint64_t expectMatcher(StringRef MatcherName) {
// Optimizations on the matcher framework make simple matchers like
}
struct FakeComparator : public PathComparator {
- ~FakeComparator() override {}
+ ~FakeComparator() override = default;
bool equivalent(StringRef FileA, StringRef FileB) const override {
return FileA.equals_lower(FileB);
}
OverlayFileSystem->pushOverlay(InMemoryFileSystem);
}
- ~RewriterTestContext() {}
+ ~RewriterTestContext() = default;
FileID createInMemoryFile(StringRef Name, StringRef Content) {
std::unique_ptr<llvm::MemoryBuffer> Source =
template <typename T>
class TestVisitor : public RecursiveASTVisitor<T> {
public:
- TestVisitor() { }
+ TestVisitor() = default;
- virtual ~TestVisitor() { }
+ virtual ~TestVisitor() = default;
enum Language {
Lang_C,