Merge "Fix false compatibility return status on extension."
This commit is contained in:
@@ -105,11 +105,15 @@ HeaderAbiDiff::ExtractUserDefinedTypes(
|
||||
continue;
|
||||
}
|
||||
const abi_util::TypeIR *type = *(odr_list.begin());
|
||||
const abi_util::RecordTypeIR *record_type = nullptr;
|
||||
switch (type->GetKind()) {
|
||||
case abi_util::RecordTypeKind:
|
||||
record_type = static_cast<const abi_util::RecordTypeIR *>(type);
|
||||
if (record_type->IsAnonymous()) {
|
||||
continue;
|
||||
}
|
||||
record_types.emplace(
|
||||
static_cast<const abi_util::RecordTypeIR *>(type)->GetUniqueId(),
|
||||
static_cast<const abi_util::RecordTypeIR *>(type));
|
||||
record_type->GetUniqueId(), record_type);
|
||||
break;
|
||||
case abi_util::EnumTypeKind:
|
||||
enum_types.emplace(
|
||||
|
||||
@@ -183,15 +183,15 @@ int main(int argc, const char **argv) {
|
||||
<< "******************************************************\n";
|
||||
}
|
||||
|
||||
if ((allow_extensions &&
|
||||
if (!advice_only && ((!allow_extensions &&
|
||||
(status & abi_util::CompatibilityStatusIR::Extension)) ||
|
||||
(allow_unreferenced_changes &&
|
||||
(!allow_unreferenced_changes &&
|
||||
(status & abi_util::CompatibilityStatusIR::UnreferencedChanges)) ||
|
||||
(allow_unreferenced_elf_symbol_changes &&
|
||||
(!allow_unreferenced_elf_symbol_changes &&
|
||||
(status & abi_util::CompatibilityStatusIR::ElfIncompatible)) ||
|
||||
advice_only) {
|
||||
return abi_util::CompatibilityStatusIR::Compatible;
|
||||
(status & abi_util::CompatibilityStatusIR::Incompatible))) {
|
||||
return status;
|
||||
}
|
||||
|
||||
return status;
|
||||
return abi_util::CompatibilityStatusIR::Compatible;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user