s/puts them/puts the result/
On Thu, Jan 11, 2018 at 8:57 AM, Axel Wagner
wrote:
> On Thu, Jan 11, 2018 at 8:10 AM, 'Eric Johnson' via golang-nuts <
> golang-nuts@googlegroups.com> wrote:
>
>> I was looking at fixing an issue flagged by gometalinter, and realized I
>> didn't understand the actua
On Thu, Jan 11, 2018 at 8:10 AM, 'Eric Johnson' via golang-nuts <
golang-nuts@googlegroups.com> wrote:
> I was looking at fixing an issue flagged by gometalinter, and realized I
> didn't understand the actual behavior of defer statements. Specifically, I
> was not handling the error return of a cl
> The body of the two functions differs only by a single ":", and yet, the
> output of the Printf calls differs.
This is not correct. The significant difference is one version has a named
return value, the other does not. The named return value allows you to capture
(by name) the return value a
I was looking at fixing an issue flagged by gometalinter, and realized I
didn't understand the actual behavior of defer statements. Specifically, I
was not handling the error return of a close operation.
I wrote a test program so I could understand the behavior, which led to
these two function