Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(307)

Issue 4121051: code review 4121051: io: add ReadRuner (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
14 years, 4 months ago by r
Modified:
14 years, 4 months ago
Reviewers:
gri, niemeyer, r2, rog
CC:
rsc, golang-dev
Visibility:
Public.

Description

io: add ReadRuner Put it in the same package as ReadByter. There is no implementation here for either interface.

Patch Set 1 #

Patch Set 2 : code review 4121051: io: add ReadRuner #

Unified diffs Side-by-side diffs Delta from patch set Stats (+9 lines, -0 lines) Patch
M src/pkg/io/io.go View 1 chunk +9 lines, -0 lines 0 comments Download

Messages

Total messages: 16
r
Hello rsc (cc: golang-dev@googlegroups.com), I'd like you to review this change.
14 years, 4 months ago (2011-02-02 04:51:03 UTC) #1
rsc
LGTM
14 years, 4 months ago (2011-02-02 05:03:46 UTC) #2
r
*** Submitted as http://code.google.com/p/go/source/detail?r=c50ac92b2a18 *** io: add ReadRuner Put it in the same package as ...
14 years, 4 months ago (2011-02-02 05:09:37 UTC) #3
gri
These names seem unfortunate. If the methods were called ByteRead RuneRead the interfaces could be ...
14 years, 4 months ago (2011-02-02 06:08:59 UTC) #4
niemeyer
> These names seem unfortunate. If the methods were called > > ByteRead > RuneRead ...
14 years, 4 months ago (2011-02-02 11:49:27 UTC) #5
r
I wanted to name the interface RuneReader but didn't, for consistency. I even considered explaining ...
14 years, 4 months ago (2011-02-02 16:00:13 UTC) #6
niemeyer
> Discussion welcome. It's very small point to change an interface > that's rarely used. ...
14 years, 4 months ago (2011-02-02 17:25:22 UTC) #7
niemeyer
Sorry, I just gave my opinion and forgot to give the background. The background is ...
14 years, 4 months ago (2011-02-02 17:32:08 UTC) #8
gri
I'd be glad with n13m3y3r@'s suggestion: Keep the method names as is, rename the interfaces. ...
14 years, 4 months ago (2011-02-02 18:01:12 UTC) #9
rog
+1 On 2 February 2011 18:01, Robert Griesemer <gri@golang.org> wrote: > I'd be glad with ...
14 years, 4 months ago (2011-02-02 18:09:56 UTC) #10
rsc
Some data about the bike shed: 1. This specific case (VerbNoun -> VerbNouner vs NounVerber) ...
14 years, 4 months ago (2011-02-02 20:29:03 UTC) #11
r2
On Feb 2, 2011, at 12:28 PM, Russ Cox wrote: > Some data about the ...
14 years, 4 months ago (2011-02-02 20:33:40 UTC) #12
niemeyer
> 2. There are some VerbPreposition -> VerberPreposition also in io: > ReaderFrom, WriterTo, ReaderAt, ...
14 years, 4 months ago (2011-02-02 21:04:59 UTC) #13
niemeyer
> I think most people want ByteReader, and gri proposes to make that change, but ...
14 years, 4 months ago (2011-02-02 21:14:16 UTC) #14
rsc
>> I am comfortable with either ReadByter or ByteReader >> as long as we stick ...
14 years, 4 months ago (2011-02-02 21:21:10 UTC) #15
r2
14 years, 4 months ago (2011-02-02 21:23:20 UTC) #16
On Feb 2, 2011, at 1:19 PM, Russ Cox wrote:

>>> I am comfortable with either ReadByter or ByteReader
>>> as long as we stick to the decision for future names.
>> 
>> I think most people want ByteReader, and gri proposes to
>> make that change, but the sticky point is whether we should
>> therefore rename the method.
> 
> I am comfortable with either of
> 
> type ByteReader interface {
>    ReadByte() (byte, os.Error)
> }
> 
> type ReadByter interface {
>    ReadByte() (byte, os.Error)
> }
> 
> I am definitely not comfortable with
> 
> type ByteReader interface {
>    ByteRead() (byte, os.Error)
> }
> 
> because ByteRead contradicts the established
> conventions for naming methods.  I thought only the
> interface name was being decided.

Then the plan is decided.

-rob


Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b