fix a bug in my previous patch, a classic =/== bug.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@50483 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Chris Lattner 2008-04-30 15:27:09 +00:00
parent d2ef523673
commit 5c5f1095ec

View File

@ -140,7 +140,7 @@ unsigned Value::getNameLen() const {
/// nul terminated string.
bool Value::isName(const char *N) const {
unsigned InLen = strlen(N);
return InLen = getNameLen() && memcmp(getNameStart(), N, InLen) == 0;
return InLen == getNameLen() && memcmp(getNameStart(), N, InLen) == 0;
}