Use method to query if there are attributes.

llvm-svn: 165213
This commit is contained in:
Bill Wendling
2012-10-04 07:19:46 +00:00
parent daf8e38ba8
commit db0dbd8868

View File

@@ -482,7 +482,7 @@ bool BitcodeReader::ParseAttributeBlock() {
}
for (unsigned i = 0, e = Record.size(); i != e; i += 2) {
if (Attributes(Record[i+1]) != Attribute::None)
if (Attributes(Record[i+1]).hasAttributes())
Attrs.push_back(AttributeWithIndex::get(Record[i],
Attributes(Record[i+1])));
}