News

Android Coding Revamp Continues with Go Upgrade

From traditional coding with Java in the venerable Eclipse IDE, the new normal for Android app development may soon be programming with the young Go language in the brand-new Android Studio.

The Google Inc. revamp of the Android development ecosystem is continuing with an upgrade that for the first time lets developers code complete Android apps entirely in the nascent Google Go language.

Only 5 years old, Go last week was upgraded to version 1.4, keeping a six-month release cadence from version 1.3.

"The most notable new feature in this release is official support for Android," said Google's Andrew Gerrand in a blog post last week. "Using the support in the core and the libraries in the golang.org/x/mobile repository, it is now possible to write simple Android apps using only Go code. At this stage, the support libraries are still nascent and under heavy development. Early adopters should expect a bumpy ride, but we welcome the community to get involved."

Bumpy ride, indeed. The Go upgrade follows other major shakeups to the Google kingdom, such as the release of its homegrown Android Studio 1.0 and its designation as the official IDE for Android programming -- replacing Eclipse -- and the ongoing OS upgrade from KitKat to Lollipop, otherwise known as Android 5.0.

The open source Go language is described by Wikipedia as "a statically typed language with syntax loosely derived from that of C, adding garbage collection, type safety, some dynamic-typing capabilities, additional built-in types such as variable-length arrays and key-value maps, and a large standard library." Google describes it as "an expressive, concurrent, garbage-collected programming language."

Besides the new support of building simple Android apps, there were few major features announced in version 1.4. "It contains only one tiny language change, in the form of a backward-compatible simple variant of for-range loop, and a possibly breaking change to the compiler involving methods on pointers-to-pointers," according to release notes.

"The release focuses primarily on implementation work, improving the garbage collector and preparing the ground for a fully concurrent collector to be rolled out in the next few releases," the release notes state. "There are some new tools available, including support in the go command for build-time source code generation. The release also adds support for ARM processors on Android and Native Client (NaCl) and for AMD64 on Plan 9."

The real importance may be in its affect on Java programming for Android, perhaps serving up a clue to the question posed in 2012 by Android Authority: "Will Android switch from Java to Go?"

Gerrand didn't answer that question last month while reviewing the five-year history of Go in another blog post. But he did pose his own question. "So, what does the future hold?" he wrote. "We think that 2015 will be Go's biggest year yet." He noted that version 1.4 lays the groundwork to support Go running on mobile devices, along with support for the new low-latency garbage collector. "We expect the new [garbage collector] to be available in Go 1.5, due June 1, 2015, which will make Go appealing for a broader range of applications. We can't wait to see where people take it."

In case it goes far, Android app developers may want to check out the Java Code Geeks article that provides an introduction to "Go for Java Programmers."

About the Author

David Ramel is the editor of Visual Studio Magazine.

Featured

Upcoming Events

AppTrends

Sign up for our newsletter.

I agree to this site's Privacy Policy.