So far as I know there's no reason we can't use -source 1.7: I've done so myself a few times for various reasons on Fennec and nothing exploded.
Important to note, however, not everything is perfectly supported on the language feature front: http://stackoverflow.com/questions/7153989/java-7-language-features-with-android The most interesting toy that's broken is try-with-resources, alas. Still, diamonds, multi-catch, string in switch, all these shiny things work. (Do remember that string-switch compiles to a chain of if-statements, so there's no performance benefit to using it: just sanity). Would you like a generated patch to apply some/all of these across the board? On 14/08/14 15:18, Jim (Ningjie) Chen wrote: > \o/ Is there anything preventing us from switching our -source flag > to Java 7? I've been wanting to use some Java 7 features like > string switch and multi-catch. We've been asking people to update > to JDK 7 so I think we'll be okay? > > Wesley Johnston <[email protected]> wrote: > > Starting today, we finally have SDK20 and OpenJDK1.7 running on the > builders! That means you have new API's available to you! It also > means you have to be even more careful when using those API's to > make sure you have fallbacks in place for older Android versions. > > I also turned on Chromecast support which means we're including > Google Play Services in the APK. Note, Google Play Services is > actually just a set of classes that proxy calls to the actual > Google Play Services APK, which the user may not have installed. So > if you decide you need one of those API's be careful to check that > its installed first: > > https://developer.android.com/reference/com/google/android/gms/common/GooglePlayServicesUtil.html#isGooglePlayServicesAvailable%28android.content.Context%29 > > The JDK and SDK upgrades shouldn't affect your private builds > (yet). The GPS requirement may require you to load the sdk manager > and install Google Play Services. File bugs if that doesn't work! > > - Wes _______________________________________________ > mobile-firefox-dev mailing list [email protected] > https://mail.mozilla.org/listinfo/mobile-firefox-dev > _______________________________________________ mobile-firefox-dev > mailing list [email protected] > https://mail.mozilla.org/listinfo/mobile-firefox-dev > _______________________________________________ mobile-firefox-dev mailing list [email protected] https://mail.mozilla.org/listinfo/mobile-firefox-dev

