From: Shenghou Ma
-func findMarker(c <-chan int) int { +func findMarker(c <-chan int) int { for i := range c { - if x := <-c; isMarker(x) { + if x := <-c; isMarker(x) { return x } } @@ -3240,7 +3240,7 @@ is also allowed and follows from the general rules above.-const c = 3 < 4 // c is the untyped bool constant true +const c = 3 < 4 // c is the untyped bool constant true type MyBool bool var x, y int @@ -3550,7 +3550,7 @@ using a pointer will automatically dereference that pointer:pt.Mv
As with method calls, a reference to a non-interface method with a pointer receiver -using an addressable value will automatically take the address of that value:
t.Mv
is equivalent to(&t).Mv
. +using an addressable value will automatically take the address of that value:t.Mp
is equivalent to(&t).Mp
.