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

Issue 4094041: code review 4094041: scanner: error handler must be provided to Init (Closed)

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

Description

scanner: error handler must be provided to Init Init may report an error on the first character and thus one needs an ability to set the error handler for Init. Was a design bug. Added corresponding test cases and better documentation. Also: Fixed a subtle infinite loop exposed by one of the new test cases. Fixes issue 1380.

Patch Set 1 #

Patch Set 2 : code review 4094041: scanner: error handler must be provided to Init #

Patch Set 3 : code review 4094041: scanner: error handler must be provided to Init #

Total comments: 4

Patch Set 4 : code review 4094041: scanner: error handler must be provided to Init #

Patch Set 5 : code review 4094041: scanner: error handler must be provided to Init #

Unified diffs Side-by-side diffs Delta from patch set Stats (+31 lines, -13 lines) Patch
M src/pkg/scanner/scanner.go View 1 2 3 9 chunks +26 lines, -12 lines 0 comments Download
M src/pkg/scanner/scanner_test.go View 1 2 3 4 chunks +5 lines, -1 line 0 comments Download

Messages

Total messages: 5
gri
Hello rsc (cc: golang-dev@googlegroups.com), I'd like you to review this change.
14 years, 4 months ago (2011-01-21 02:06:32 UTC) #1
rsc
LGTM Okay if you want, but I think the API would be nicer to use ...
14 years, 4 months ago (2011-01-21 22:18:15 UTC) #2
gri1
I've fixed this as suggested with with no API change (well, the scanner position is ...
14 years, 4 months ago (2011-01-24 22:08:23 UTC) #3
rsc
LGTM
14 years, 4 months ago (2011-01-24 22:10:32 UTC) #4
gri
14 years, 4 months ago (2011-01-24 22:12:30 UTC) #5
*** Submitted as http://code.google.com/p/go/source/detail?r=65b92948f9ee ***

scanner: error handler must be provided to Init

Init may report an error on the first character and
thus one needs an ability to set the error handler
for Init. Was a design bug.

Added corresponding test cases and better documentation.
Also: Fixed a subtle infinite loop exposed by one of the
new test cases.

Fixes issue 1380.

R=rsc, gri
CC=golang-dev
http://codereview.appspot.com/4094041
Sign in to reply to this message.

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