Disclaimer: All performance claims are from a combination of personal experimentation in several projects, and from the Ubuntu x64 quad-core benchmarks, which I believe to be the best indication of future performance contrasts.
The Good
- Syntax is familiar and similar to C.
- Outperforms Python by an order and a half of magnitude.
- Compiles to binary.
- Standard library is Unix/POSIX inspired and broken up into modules.
- The standard is very short, and readable.
- Use of C-like primitives allows for cheap C interfaces.
- Replaces header/source paradigm for enormous compilation speed ups.
- Provides defer, an alternative to the exception/destructors of C++, and nested-if/goto chains of C.
- Does not have assertions. Coupled with easier resource management than C (and less boilerplate than C++), this is manageable and robust.
- Uses the := operator.
- Syntax not similar to Python. For a new language I'm not sure there is any reason to continue using C-syntax such as braces. Providing gofmt, and requiring leading braces were excellent decisions, and a large step towards whitespace formatting anyway.
- Preference for custom compiler bars adoption and integration with existing technologies.
- Limited support for Windows. Despite the pain of developing for Windows, this blocks mass adoption.
- Standard library is still evolving.
- Won't replace C in its current state. Some of the syntax and interface advances would be most welcome however.
- Performance is nowhere near C, or C++. The standard library is severely under-optimized.
- The LLVM toolchain was not chosen to build upon.
- Several years of tool chain development and optimization are required before Go will be a contender.
- Documentation of the toolchain is lacking.
- Go is much faster and has superior concurrency to Python. Retains many of strengths of Python's typing system but without dynamic typing. Python has easier syntax, and a much better standard library implementation.
- Go has better type safety than C. It also supports interfaces, closures, containers and many modern features that C lacks. Go is garbage collected, and has safe pointers. C is much faster, and has much better platform support.
- Go is much simpler than C++, and supports many modern features that are clunky and difficult to use in C++. There is far less boilerplate. C++ is faster and has better platform support.
- Go is faster than Java, and has less boilerplate. Its compilation speed, runtime size, and similarity to C will allow it to compete with Java's claim to portability.
3 comments:
"Go is faster than Java" Huh? http://shootout.alioth.debian.org/u32q/benchmark.php?test=all&lang=go&lang2=java
Braces are FAR better than indention. That is not bad AT ALL.
It could be said to be a matter of taste, if you start reading up on *why* indentation was chosen it starts to seem like a good idea.
Braces are just extra line noise.
Post a Comment