From cc56be2830e7a7aebf3e57f4c3e4ca4f019be11c Mon Sep 17 00:00:00 2001 From: George Burgess IV Date: Tue, 18 Apr 2017 01:04:05 +0000 Subject: [PATCH] Add const to a const method. NFC git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@300520 91177308-0d34-0410-b5e6-96231b3b80d8 --- include/llvm/Support/Regex.h | 2 +- lib/Support/Regex.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/include/llvm/Support/Regex.h b/include/llvm/Support/Regex.h index 83db80359ee..f498835bcb5 100644 --- a/include/llvm/Support/Regex.h +++ b/include/llvm/Support/Regex.h @@ -57,7 +57,7 @@ namespace llvm { /// isValid - returns the error encountered during regex compilation, or /// matching, if any. - bool isValid(std::string &Error); + bool isValid(std::string &Error) const; /// getNumMatches - In a valid regex, return the number of parenthesized /// matches it contains. The number filled in by match will include this diff --git a/lib/Support/Regex.cpp b/lib/Support/Regex.cpp index 68ba79e1176..b1087fd8853 100644 --- a/lib/Support/Regex.cpp +++ b/lib/Support/Regex.cpp @@ -48,7 +48,7 @@ Regex::~Regex() { } } -bool Regex::isValid(std::string &Error) { +bool Regex::isValid(std::string &Error) const { if (!error) return true; -- 2.50.1