- 28 Feb, 2013 1 commit
-
-
Rob Pike authored
R=golang-dev, bradfitz CC=golang-dev https://golang.org/cl/7439046
-
- 15 Feb, 2013 1 commit
-
-
Russ Cox authored
Fixes #4644. R=r, adonovan CC=golang-dev https://golang.org/cl/7307083
-
- 11 Feb, 2013 3 commits
-
-
Russ Cox authored
This is documenting the status quo. The previous cleanup added this language as an implementation restriction, but at least for now it is really part of the language proper. Fixes #4605. R=golang-dev, r CC=golang-dev https://golang.org/cl/7305071
-
Russ Cox authored
The gc compilers already behave this way. It was an explicit decision during the very long constant design discussions, but it appears not to have made it into the spec. Fixes #4398. R=golang-dev, r CC=golang-dev https://golang.org/cl/7313069
-
Russ Cox authored
Fixes #4586. R=golang-dev, remyoudompheng, r CC=golang-dev https://golang.org/cl/7307082
-
- 09 Feb, 2013 2 commits
-
-
Russ Cox authored
The spec is not clear about whether this is allowed or not, but both compilers allow it, because the reflect implementation takes advantage of it. Document current behavior. Fixes #4679. R=golang-dev, r CC=golang-dev https://golang.org/cl/7303064
-
Russ Cox authored
Fixes #4573. R=golang-dev, bradfitz CC=golang-dev https://golang.org/cl/7322043
-
- 24 Jan, 2013 1 commit
-
-
Oling Cat authored
R=golang-dev, adg CC=golang-dev https://golang.org/cl/7198048
-
- 21 Jan, 2013 1 commit
-
-
Shenghou Ma authored
Fixes #4682. R=golang-dev, adg, dave CC=golang-dev https://golang.org/cl/7094062
-
- 18 Jan, 2013 1 commit
-
-
Robert Griesemer authored
Fixes #4653. R=rsc, r, iant, ken, thakis CC=golang-dev https://golang.org/cl/7135058
-
- 17 Jan, 2013 1 commit
-
-
Shenghou Ma authored
R=mdempsky, iant, r, gri, rsc, ken CC=golang-dev https://golang.org/cl/7100046
-
- 09 Jan, 2013 1 commit
-
-
Robert Griesemer authored
Fixes #4612. R=rsc, iant, ken, r CC=golang-dev https://golang.org/cl/7076043
-
- 08 Jan, 2013 1 commit
-
-
Robert Griesemer authored
The spec talks explicitly about rune literals but the respective production is still called char_lit for historic reasons. Updated the two occurences. Fixes #4602. R=rsc, iant, r, ken CC=golang-dev https://golang.org/cl/7070048
-
- 07 Jan, 2013 1 commit
-
-
Matthew Dempsky authored
Replacing division-by-power-of-2 with right-shift is valid for zero too. R=gri CC=golang-dev https://golang.org/cl/7027049
-
- 03 Jan, 2013 1 commit
-
-
Robert Griesemer authored
A composite literal may be parenthesized when used as operand for the unary operator &. R=rsc, iant, r, ken CC=golang-dev https://golang.org/cl/6996053
-
- 12 Dec, 2012 3 commits
-
-
Robert Griesemer authored
Fixes #3814. R=rsc, iant CC=golang-dev https://golang.org/cl/6920057
-
Robert Griesemer authored
This is language change. It is a backward-compatible change but for code that relies on a run-time panic when calling delete on a nil map (unlikely). Fixes #4253. R=rsc, r, iant, ken, bradfitz, rogpeppe CC=golang-dev https://golang.org/cl/6909060
-
Robert Griesemer authored
R=r, rsc, iant, ken CC=golang-dev https://golang.org/cl/6903048
-
- 11 Dec, 2012 1 commit
-
-
Robin Eklind authored
Also, remove unnecessary whitespace. R=golang-dev, rsc CC=golang-dev https://golang.org/cl/6928045
-
- 10 Dec, 2012 1 commit
-
-
Robert Griesemer authored
We have been using all three terms "indices", "indexes", and "index expressions" indiscriminatly for index values. With this change, "index" refers to an index value, "indices" is the plural of "index", and "index expression" refers to an array, slice, or map indexed by an index: a[x]. R=r, rsc, iant, ken, mtj CC=golang-dev https://golang.org/cl/6912056
-
- 06 Dec, 2012 2 commits
-
-
Robert Griesemer authored
Fixes #4457. R=rsc, iant, r, ken CC=golang-dev https://golang.org/cl/6862046
-
Robert Griesemer authored
The spec didn't preclude invalid type assertions and type switches, i.e., cases where a concrete type doesn't implement the interface type in the assertion in the first place. Both, the gc and gccgo compiler exclude these cases. This is documenting the status quo. Also: - minor clean up of respective examples - added sentence about default case in select statements Fixes #4472. R=rsc, iant, r, ken CC=golang-dev https://golang.org/cl/6869050
-
- 04 Dec, 2012 1 commit
-
-
Robert Griesemer authored
Also: fix an incorrect link. Fixes #4479. Fixes #4456. R=rsc, iant, r, ken CC=golang-dev https://golang.org/cl/6868062
-
- 03 Dec, 2012 1 commit
-
-
Robert Griesemer authored
Also: - 'for' statements with a range clause do not accept send-only channels - '_, _ = range ch' is not equivalent to "_ = range ch" if ch is a channel (rewriting the latter to the former leads to an invalid range clause). These clarifications document the status quo. R=rsc, r, iant, ken CC=golang-dev https://golang.org/cl/6874053
-
- 29 Nov, 2012 2 commits
-
-
Robert Griesemer authored
Fixes #4450. R=rsc, iant CC=golang-dev https://golang.org/cl/6845104
-
Robert Griesemer authored
1) Built-ins are restricted like for expression statements. This documents the status quo. 2) Calls cannot be parenthesized. The spec is not clear. gccgo permits it already, gc doesn't. Be explicit in the spec. Fixes #4462. R=rsc, iant, r, ken, lvd CC=golang-dev https://golang.org/cl/6861043
-
- 26 Nov, 2012 1 commit
-
-
Russ Cox authored
Since p.M is rejected (must call methods), use p.M(), to keep the examples compiling. Fixes #4441. R=gri CC=golang-dev https://golang.org/cl/6854096
-
- 21 Nov, 2012 1 commit
-
-
Robert Griesemer authored
We have the notion of a PackageName, not package identifier. As is, it could construed that imports that rename a package don't have an "imported package identifier" but a local one. R=r, rsc, iant, ken, dsymonds CC=golang-dev https://golang.org/cl/6858049
-
- 17 Nov, 2012 1 commit
-
-
Robert Griesemer authored
Fixes #4400. R=r, mirtchovski CC=golang-dev https://golang.org/cl/6782084
-
- 02 Nov, 2012 1 commit
-
-
Oling Cat authored
R=golang-dev CC=golang-dev https://golang.org/cl/6818083
-
- 01 Nov, 2012 1 commit
-
-
Robert Griesemer authored
This is an attempt at making the interaction between these three constructs clearer. Specifically: - return statements terminate a function, execute deferred functions, return to the caller, and then execution continues after the call - panic calls terminate a function, execute deferred functions, return to the caller, and then re-panic - deferred functions are executed before a function _returns_ to its caller The hope is that with this change it becomes clear when a deferred function is executed (when a function returns), and when it is not (when a program exits). R=r, rsc, iant, ken, iant CC=golang-dev https://golang.org/cl/6736071
-
- 31 Oct, 2012 2 commits
-
-
Robert Griesemer authored
Fixes #4324. R=r CC=golang-dev https://golang.org/cl/6822062
-
Rob Pike authored
R=golang-dev, rsc CC=golang-dev https://golang.org/cl/6812060
-
- 19 Oct, 2012 2 commits
-
-
Robert Griesemer authored
Both gc and gccgo always checked this for constant expressions but the spec only mentions run-time exceptions. This CL also requires that constant divisors must not be zero in non-constant integer expressions: This is consistent with the spirit of the most recent changes and it is consistent with constant expressions. We don't want to specify the effect for non-integer expressions (f/0.0 where f is a float or complex number) because there the result f/g is not further specified if a non-constant g is 0. R=r, rsc, iant, ken, andybalholm, iant CC=golang-dev https://golang.org/cl/6710045
-
Robert Griesemer authored
This is a language change: Until now, the spec required run- time panics for some of these errors. Note that gc and gccgo implemented this inconsistently, and that both compilers already reported compile-time errors in some cases. This change makes make() behave along the same vein as index expressions. This addresses the spec aspect of issue 4085. R=r, rsc, iant, ken CC=golang-dev https://golang.org/cl/6725053
-
- 17 Oct, 2012 1 commit
-
-
Robert Griesemer authored
At the moment, gc and gccgo report compile- time errors for certain constant indexes that are out of bounds. The spec however requests a run-time panic for out-of-bounds indexes (http://tip.golang.org/ref/spec#Indexes). Document the status quo. Fixes #4231. R=r, rsc, iant, ken CC=golang-dev https://golang.org/cl/6699048
-
- 16 Oct, 2012 1 commit
-
-
Rob Pike authored
Proposed new text to make matters clearer. The existing text was unclear about the state of result parameters when panicking. R=golang-dev, iant CC=golang-dev https://golang.org/cl/6653047
-
- 10 Oct, 2012 1 commit
-
-
Rob Pike authored
It's already there but only in the "for instance" and so not clear enough: deferred functions run after the result parameters are updated. R=golang-dev, dsymonds CC=golang-dev https://golang.org/cl/6631058
-
- 03 Oct, 2012 1 commit
-
-
Robert Griesemer authored
Also: Be explicit what operator means with respect to conversion types. The parenthesis requirement is a language change. At the moment, literal function types in conversions that cannot possibly be followed by a '(' don't need parentheses. For instance: func(int)int(x) -> same as (func(int)int)(x) func()()(x) -> same as (func())(x) but: func(int)(x) -> could be func(int)x {...} Fixes #4109. R=rsc, r, iant, ken, iant CC=golang-dev https://golang.org/cl/6584065
-
- 28 Sep, 2012 1 commit
-
-
Robert Griesemer authored
Fixes #4142. R=rsc, r, iant, ken, remyoudompheng CC=golang-dev https://golang.org/cl/6567062
-