From 044eb2f6afba375a914ac9d8024f8f5142bb912e Mon Sep 17 00:00:00 2001 From: Dimitry Andric Date: Mon, 18 Dec 2017 20:10:56 +0000 Subject: Vendor import of llvm trunk r321017: https://llvm.org/svn/llvm-project/llvm/trunk@321017 --- include/llvm/TableGen/Error.h | 2 ++ include/llvm/TableGen/Record.h | 2 +- include/llvm/TableGen/StringMatcher.h | 7 ++++--- 3 files changed, 7 insertions(+), 4 deletions(-) (limited to 'include/llvm/TableGen') diff --git a/include/llvm/TableGen/Error.h b/include/llvm/TableGen/Error.h index 3df658df8809..de4d3bf54782 100644 --- a/include/llvm/TableGen/Error.h +++ b/include/llvm/TableGen/Error.h @@ -19,6 +19,8 @@ namespace llvm { +void PrintNote(ArrayRef NoteLoc, const Twine &Msg); + void PrintWarning(ArrayRef WarningLoc, const Twine &Msg); void PrintWarning(const char *Loc, const Twine &Msg); void PrintWarning(const Twine &Msg); diff --git a/include/llvm/TableGen/Record.h b/include/llvm/TableGen/Record.h index fa9ca285bcde..55b4dfe2fa2f 100644 --- a/include/llvm/TableGen/Record.h +++ b/include/llvm/TableGen/Record.h @@ -1638,7 +1638,7 @@ struct LessRecordRegister { if (LHSNumParts != RHSNumParts) return LHSNumParts < RHSNumParts; - // We expect the registers to be of the form [_a-zA-z]+([0-9]*[_a-zA-Z]*)*. + // We expect the registers to be of the form [_a-zA-Z]+([0-9]*[_a-zA-Z]*)*. for (size_t I = 0, E = LHSNumParts; I < E; I+=2) { std::pair LHSPart = LHSParts.getPart(I); std::pair RHSPart = RHSParts.getPart(I); diff --git a/include/llvm/TableGen/StringMatcher.h b/include/llvm/TableGen/StringMatcher.h index 7c919ffec7b6..09d2092d43b0 100644 --- a/include/llvm/TableGen/StringMatcher.h +++ b/include/llvm/TableGen/StringMatcher.h @@ -43,11 +43,12 @@ public: const std::vector &matches, raw_ostream &os) : StrVariableName(strVariableName), Matches(matches), OS(os) {} - void Emit(unsigned Indent = 0) const; + void Emit(unsigned Indent = 0, bool IgnoreDuplicates = false) const; private: - bool EmitStringMatcherForChar(const std::vector &Matches, - unsigned CharNo, unsigned IndentCount) const; + bool EmitStringMatcherForChar(const std::vector &Matches, + unsigned CharNo, unsigned IndentCount, + bool IgnoreDuplicates) const; }; } // end namespace llvm -- cgit v1.2.3