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

Issue 5305066: code review 5305066: gofix: error fix (Closed)

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

Description

gofix: error fix To make the error fix more useful, expand typecheck to gather more information about struct fields, typecheck range statements, typecheck indirect and index of named types, and collect information about assignment conversions. Also, change addImport to rename top-level uses of a to-be-imported identifier to avoid conflicts. This duplicated some of the code in the url fix, so that fix is now shorter.

Patch Set 1 #

Patch Set 2 : diff -r 181517df0815 https://go.googlecode.com/hg/ #

Patch Set 3 : diff -r 3f70682b9214 https://go.googlecode.com/hg/ #

Patch Set 4 : diff -r a7ee8dfa634d https://go.googlecode.com/hg/ #

Patch Set 5 : diff -r a7ee8dfa634d https://go.googlecode.com/hg/ #

Total comments: 7

Patch Set 6 : diff -r db6289ea7a02 https://go.googlecode.com/hg/ #

Patch Set 7 : diff -r 2be61232b4e2 https://go.googlecode.com/hg/ #

Unified diffs Side-by-side diffs Delta from patch set Stats (+805 lines, -65 lines) Patch
M src/cmd/gofix/Makefile View 1 1 chunk +1 line, -0 lines 0 comments Download
A src/cmd/gofix/error.go View 1 2 3 4 5 1 chunk +352 lines, -0 lines 0 comments Download
A src/cmd/gofix/error_test.go View 1 1 chunk +232 lines, -0 lines 0 comments Download
M src/cmd/gofix/fix.go View 1 2 3 5 chunks +96 lines, -5 lines 0 comments Download
M src/cmd/gofix/httpheaders.go View 1 1 chunk +1 line, -1 line 0 comments Download
M src/cmd/gofix/imagecolor.go View 1 2 chunks +3 lines, -8 lines 0 comments Download
M src/cmd/gofix/main.go View 1 2 3 4 3 chunks +13 lines, -4 lines 0 comments Download
M src/cmd/gofix/math.go View 1 2 3 4 5 6 1 chunk +1 line, -8 lines 0 comments Download
M src/cmd/gofix/reflect.go View 1 1 chunk +1 line, -1 line 0 comments Download
M src/cmd/gofix/signal.go View 1 1 chunk +3 lines, -5 lines 0 comments Download
M src/cmd/gofix/typecheck.go View 1 2 3 4 12 chunks +98 lines, -11 lines 0 comments Download
M src/cmd/gofix/url.go View 1 2 3 4 5 4 chunks +2 lines, -20 lines 0 comments Download
M src/cmd/gofix/url_test.go View 1 2 3 1 chunk +2 lines, -2 lines 0 comments Download

Messages

Total messages: 7
rsc
Hello golang-dev@googlegroups.com, I'd like you to review this change to https://go.googlecode.com/hg/
13 years, 4 months ago (2011-10-28 04:11:31 UTC) #1
iant
LGTM http://codereview.appspot.com/5305066/diff/10001/src/cmd/gofix/error.go File src/cmd/gofix/error.go (right): http://codereview.appspot.com/5305066/diff/10001/src/cmd/gofix/error.go#newcode35 src/cmd/gofix/error.go:35: Error field or method is renamed to Err. ...
13 years, 4 months ago (2011-10-30 04:39:28 UTC) #2
r
the DL desc is missing some information i need. http://codereview.appspot.com/5305066/diff/10001/src/cmd/gofix/typecheck.go File src/cmd/gofix/typecheck.go (right): http://codereview.appspot.com/5305066/diff/10001/src/cmd/gofix/typecheck.go#newcode132 src/cmd/gofix/typecheck.go:132: ...
13 years, 4 months ago (2011-10-31 19:10:35 UTC) #3
r2
s/DL/CL/
13 years, 4 months ago (2011-10-31 19:11:37 UTC) #4
rsc
http://codereview.appspot.com/5305066/diff/10001/src/cmd/gofix/typecheck.go File src/cmd/gofix/typecheck.go (right): http://codereview.appspot.com/5305066/diff/10001/src/cmd/gofix/typecheck.go#newcode132 src/cmd/gofix/typecheck.go:132: // It returns two maps with type information: On ...
13 years, 4 months ago (2011-10-31 21:40:26 UTC) #5
rsc
> src/cmd/gofix/error.go:35: Error field or method is renamed to Err. > Also any top level ...
13 years, 4 months ago (2011-10-31 21:40:57 UTC) #6
rsc
13 years, 4 months ago (2011-11-02 01:45:24 UTC) #7
*** Submitted as http://code.google.com/p/go/source/detail?r=45374320621e ***

gofix: error fix

To make the error fix more useful, expand typecheck to gather
more information about struct fields, typecheck range statements,
typecheck indirect and index of named types, and collect information
about assignment conversions.

Also, change addImport to rename top-level uses of a to-be-imported
identifier to avoid conflicts.  This duplicated some of the code in 
the url fix, so that fix is now shorter.

R=iant, r, r
CC=golang-dev
http://codereview.appspot.com/5305066
Sign in to reply to this message.

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