51 #ifndef LLVM_SUPPORT_SPECIALCASELIST_H 52 #define LLVM_SUPPORT_SPECIALCASELIST_H 71 static std::unique_ptr<SpecialCaseList>
80 static std::unique_ptr<SpecialCaseList>
121 bool insert(std::string Regexp,
unsigned LineNumber, std::string &REError);
129 std::vector<std::pair<std::unique_ptr<Regex>,
unsigned>> RegExes;
135 Section(std::unique_ptr<Matcher> M) : SectionMatcher(
std::move(M)){};
155 #endif // LLVM_SUPPORT_SPECIALCASELIST_H
unsigned inSectionBlame(StringRef Section, StringRef Prefix, StringRef Query, StringRef Category=StringRef()) const
Returns the line number corresponding to the special case list entry if the special case list contain...
This class represents lattice values for constants.
bool inSection(StringRef Section, StringRef Prefix, StringRef Query, StringRef Category=StringRef()) const
Returns true, if special case list contains a line.
std::unique_ptr< Matcher > SectionMatcher
unsigned match(StringRef Query) const
bool parse(const MemoryBuffer *MB, StringMap< size_t > &SectionsMap, std::string &Error)
Parses just-constructed SpecialCaseList entries from a memory buffer.
bool createInternal(const std::vector< std::string > &Paths, vfs::FileSystem &VFS, std::string &Error)
SpecialCaseList()=default
static std::unique_ptr< SpecialCaseList > createOrDie(const std::vector< std::string > &Paths, llvm::vfs::FileSystem &FS)
Parses the special case list entries from files.
SpecialCaseList & operator=(SpecialCaseList const &)=delete
std::vector< Section > Sections
The virtual file system interface.
This interface provides simple read-only access to a block of memory, and provides simple methods for...
Represents a set of regular expressions.
Defines the virtual file system interface vfs::FileSystem.
static std::unique_ptr< SpecialCaseList > create(const std::vector< std::string > &Paths, llvm::vfs::FileSystem &FS, std::string &Error)
Parses the special case list entries from files.
bool insert(std::string Regexp, unsigned LineNumber, std::string &REError)
Lightweight error class with error context and mandatory checking.
StringRef - Represent a constant reference to a string, i.e.