diff options
Diffstat (limited to 'src/util')
-rw-r--r-- | src/util/regexp.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/util/regexp.h b/src/util/regexp.h index f6c5b2b0f..82b838315 100644 --- a/src/util/regexp.h +++ b/src/util/regexp.h @@ -130,6 +130,11 @@ public: return true; } + bool rstrncmp(const String &y, unsigned int n) const { + for(unsigned int i=0; i<n; ++i) + if(d_str[d_str.size() - i - 1] != y.d_str[y.d_str.size() - i - 1]) return false; + return true; + } bool isEmptyString() const { return ( d_str.size() == 0 ); |