Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit aa41dac8 authored by Mårten Kongstad's avatar Mårten Kongstad
Browse files

check-flagged-apis: make interfaces inherit from java/lang/Object

When parsing API signature files, check-flagged-apis relies on
ClassItem.superClass to get the parent class of a class or interface.
That method always returns null for interfaces.

When generating api-versions.xml, metalava marks interface classes as
inheriting from java/lang/Object:

  <class name="android/os/Parcelable" since="1">
    <extends name="java/lang/Object"/>
    [...]
  </class>

This confuses check-flagged-apis when comparing data parsed from both
sources, as the symbol signatures will be identical, but the superclass
entries differ. Work around this by explicitly marking all interfaces
as inheriting from java/lang/Object when parsing API signature files.

Bug: 334870672
Test: atest --host check-flagged-apis-test
Change-Id: Icbb8f7d4c3d4232a083289a778b347e33a0856ab
parent 0ea5497c
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment