Closed Bug 843557 Opened 13 years ago Closed 13 years ago

Fennec fails to build with Java 7 due to multiple warnings

Categories

(Firefox for Android Graveyard :: General, defect)

All
Android
defect
Not set
minor

Tracking

(Not tracked)

RESOLVED FIXED
Firefox 22

People

(Reporter: admin, Assigned: kats)

References

Details

Attachments

(2 files)

Changeset 7547bf5fe166 (https://hg.mozilla.org/integration/mozilla-inbound/rev/7547bf5fe166) added a type parameter to GeckoMenuItem.Layout. This causes Java 7 builds to fail when treating warnings as errors as none of the references to GeckoMenuItem.Layout have defined parameters. Warnings at: /mobile/android/base/GeckoMenuItem.java:41 /mobile/android/base/MenuItemActionBar.java:16 /mobile/android/base/MenuItemDefault.java:19
Summary: Fennec fails to build with Java 7 because of multiple warnings → Fennec fails to build with Java 7 due to multiple warnings
I couldn't install Java 7 on Mac to try this. Could someone with a linux machine fix it? I basically missed the specific types with implementing the interface.
Attached patch PatchSplinter Review
y u add useless generic?
Attachment #716733 - Flags: review?(sriram)
Comment on attachment 716733 [details] [diff] [review] Patch Review of attachment 716733 [details] [diff] [review]: ----------------------------------------------------------------- If the cast works without using Generics, I am happy with it. :)
Attachment #716733 - Flags: review?(sriram) → review+
inbound is closed, so tagging for checkin.
Assignee: nobody → bugmail.mozilla
Status: UNCONFIRMED → NEW
Ever confirmed: true
Keywords: checkin-needed
(In reply to Kartikaya Gupta (email:kats@mozilla.com) from comment #2) > Created attachment 716733 [details] [diff] [review] > Patch > > y u add useless generic? Drive-by: some previous patch in GeckoMenuItem seems to assume that the use of generics there makes it ok to cast this Layout interface to View which is not exactly correct. A more complete fix for this warning should probably include adding something like a getView() method to the layout interface (or something similar) and replace all the castings from Layout to View.
This revert the methods back into interface. /me accepts his fault.
Attachment #716809 - Flags: review?(bugmail.mozilla)
Attachment #716809 - Flags: review?(bugmail.mozilla) → review+
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 22
Product: Firefox for Android → Firefox for Android Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: