Google Introduces ‘Go’ Programming Language

Go is new open source programming language

Rob Pike, a principal engineer at Google said “I’ve never felt as productive as I have working with Go”

Pike says Go’s goal is to serve as a systems language, in the way that C++ or C does today

“It’s fast for development but it also is a true compiled language,” he explained. “We’re opening sourcing it now because we think it’s reached the point of being fun and useful and powerful.”


How did we get here?

1) C and Unix became dominant in research.

2) The desire for a higher-level language led to C++, which grafted the Simula style of object-oriented

programming onto C. It was a poor fit but since it compiled to C it brought high-level programming to Unix.

3) C++ became the language of choice in parts of industry and in many research universities.

4) Java arose as a clearer, stripped-down C++.

5) By the late 1990s, a teaching language was needed that seemed relevant, and Java was chosen.


*A number of successful simpler languages (Python, Ruby, Lua, JavaScript, Erlang, …) have become popular, in part as a rejection of the standard languages.

*Some beautiful and rigorous languages designed by domain experts (Scala, Haskell, …) have also arisen, although they are not as widely adopted.

*The standard languages (Java, C++) are statically typed.

*Most outsider languages (Ruby, Python, JavaScript) are interpreted and dynamically typed.

*Perhaps as a result, non-expert programmers have confused “ease of use” with interpretation and dynamic typing.

*This confusion arose because of how we got here: grafting an orthodoxy onto a language that couldn’t support it cleanly.


#the good

* The standard languages are very strong: type-safe, effective, efficient.

* In the hands of experts, they are great.

* Huge systems and huge companies are built on them.

* In practice they work well for large scale programming: big programs, many programmers.

#The bad

* The standard languages are hard to use.

* Compilers are slow and fussy. Binaries are huge.

* Effective work needs language-aware tools, distributed compilation farms, …

* Many programmers prefer to avoid them.

* The languages are at least 10 years old and poorly adapted

to the current computing environment: clouds of networked

multi-core CPUs.


This is partly why Python have become so popular:

They don’t have much of the “bad”.

– dynamically typed (fewer noisy keystrokes)

– interpreted (no compiler to wait for)

– good tools (interpreters make things easier)

But they also don’t have the “good”:

– slow

– not type-safe (static errors occur at runtime)

– very poor at scale

And they’re also not very modern.

#There is a niche to be filled: a language that has the good,

avoids the bad, and is suitable to modern computing infrastructure:

* comprehensible

* statically typed

* light on the page

* fast to work in

* scales well

* doesn’t require tools, but supports them well

* good at networking and multiprocessing

Go is different

* Go is object-oriented not type-oriented

-inheritance is not primary

-methods on any type, but no classes or subclasses

* Go is (mostly) implicit not explicit types are inferred not declared

objects have interfaces but they are derived, not specified

*Go is concurrent not parallel

intended for program structure, not max performance
but still can keep all the cores humming nicely
… and many programs are more nicely expressed with

concurrent ideas even if not parallel at all


# compiler

* The language is designed and usable. Two compiler suites: Gc, written in C, generates OK code very quickly.

– unusual design based on the Plan 9 compiler suite Gccgo, written in C++, generates good code more slowly

Libraries good and growing, but some pieces are still preliminary

# Testimonials

“I have reimplemented a networking project from Scala to Go. Scala code is 6000 lines. Go is about 3000. Even though Go does not have the power of abbreviation, the flexible type system seems to out-run Scala when the programs start getting longer. Hence, Go produces much shorter code asymptotically.”

Petar Maymounkov (PhD candidate at MIT, Computer Science and Artificial Intelligence Lab)


“Go is unique because of the set of things it does well. It has areas for improvement, but for my needs it is the best match I’ve found when compared to: C, C++, Erlang, Python, Ruby, C#, D, Java, and Scala.”

Hans Stimer

Another Go at Language Design