TableGen: fix constness of new comparison function.
authorTim Northover <tnorthover@apple.com>
Mon, 16 Sep 2013 17:33:40 +0000 (17:33 +0000)
committerTim Northover <tnorthover@apple.com>
Mon, 16 Sep 2013 17:33:40 +0000 (17:33 +0000)
libc++ didn't seem to like a non-const call operator.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@190797 91177308-0d34-0410-b5e6-96231b3b80d8

utils/TableGen/AsmMatcherEmitter.cpp

index ff04d63d00defb5d70661fe9d6d4df4f5d367f6d..558090bbf63c28b60e85d049c28ae53e0a3ff32f 100644 (file)
@@ -1065,7 +1065,7 @@ AsmMatcherInfo::getOperandClass(Record *Rec, int SubOpIdx) {
 }
 
 struct LessRegisterSet {
-  bool operator() (const RegisterSet &LHS, const RegisterSet & RHS) {
+  bool operator() (const RegisterSet &LHS, const RegisterSet & RHS) const {
     // std::set<T> defines its own compariso "operator<", but it
     // performs a lexicographical comparison by T's innate comparison
     // for some reason. We don't want non-deterministic pointer