diff --git a/doc/go1.9.html b/doc/go1.9.html index e2ad65491a..83e1945467 100644 --- a/doc/go1.9.html +++ b/doc/go1.9.html @@ -23,12 +23,18 @@ ul li { margin: 0.5em 0; }
- The latest Go release, version 1.9, arrives six months after Go 1.8 - and is the tenth release in the Go 1.x series. - Most of its changes are in the implementation of the toolchain, runtime, and libraries. - There are no changes to the language specification. - As always, the release maintains the Go 1 promise of compatibility. - We expect almost all Go programs to continue to compile and run as before. + The latest Go release, version 1.9, arrives six months + after Go 1.8 and is the tenth release in + the Go 1.x + series. + There is one change to the language, adding + support for type aliases. + Most of the changes are in the implementation of the toolchain, + runtime, and libraries. + As always, the release maintains the Go 1 + promise of compatibility. + We expect almost all Go programs to continue to compile and run as + before.
@@ -39,6 +45,29 @@ ul li { margin: 0.5em 0; } and includes a new bit manipulation package.
++ There is one change to the language. + Go now supports type aliases to support gradual code repair while + moving a type between packages. + The type alias + design document + and an + article on refactoring cover the problem in detail. + In short, a type alias declaration has the form: +
+ ++type T1 = T2 ++ +
+ This declaration introduces an alias name T1
—an
+ alternate spelling—for the type denoted by T2
; that is,
+ both T1
and T2
denote the same type.
+
@@ -147,7 +176,7 @@ ul li { margin: 0.5em 0; }
The
new (*T).Helper
an (*B).Helper
- methods marks the calling function as a test helper function. When
+ methods mark the calling function as a test helper function. When
printing file and line information, that function will be skipped.
This permits writing test helper functions while still having useful
line numbers for users.