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

Issue 5316043: code review 5316043: gc: clean up printing. (Closed)

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

Description

gc: clean up printing. Got rid of all the magic mystery globals. Now for %N, %T, and %S, the flags +,- and # set a sticky debug, sym and export mode, only visible in the new fmt.c. Default is error mode. Handle h and l flags consistently with the least side effects, so we can now change things without worrying about unrelated things breaking. fixes issue 2361

Patch Set 1 #

Patch Set 2 : diff -r 31329f71f8e7 https://go.googlecode.com/hg/ #

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

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

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

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

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

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

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

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

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

Total comments: 52

Patch Set 12 : diff -r b3069ca75051 https://go.googlecode.com/hg/ #

Patch Set 13 : diff -r b3069ca75051 https://go.googlecode.com/hg/ #

Patch Set 14 : diff -r b3069ca75051 https://go.googlecode.com/hg/ #

Patch Set 15 : diff -r b3069ca75051 https://go.googlecode.com/hg/ #

Patch Set 16 : diff -r b3069ca75051 https://go.googlecode.com/hg/ #

Patch Set 17 : diff -r b3069ca75051 https://go.googlecode.com/hg/ #

Patch Set 18 : diff -r b3069ca75051 https://go.googlecode.com/hg/ #

Total comments: 14

Patch Set 19 : diff -r b3069ca75051 https://go.googlecode.com/hg/ #

Patch Set 20 : diff -r b3069ca75051 https://go.googlecode.com/hg/ #

Patch Set 21 : diff -r 01516e31b4f0 https://go.googlecode.com/hg/ #

Unified diffs Side-by-side diffs Delta from patch set Stats (+1693 lines, -1827 lines) Patch
M src/cmd/gc/Makefile View 1 2 3 4 5 6 7 8 9 10 11 3 chunks +2 lines, -2 lines 0 comments Download
M src/cmd/gc/const.c View 1 4 chunks +4 lines, -4 lines 0 comments Download
M src/cmd/gc/dcl.c View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 2 chunks +4 lines, -3 lines 0 comments Download
M src/cmd/gc/esc.c View 1 8 chunks +8 lines, -8 lines 0 comments Download
M src/cmd/gc/export.c View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 11 chunks +56 lines, -120 lines 0 comments Download
A src/cmd/gc/fmt.c View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 1 chunk +1519 lines, -0 lines 0 comments Download
M src/cmd/gc/gen.c View 1 1 chunk +1 line, -1 line 0 comments Download
M src/cmd/gc/go.h View 1 2 3 4 5 6 7 8 9 10 11 6 chunks +8 lines, -23 lines 0 comments Download
M src/cmd/gc/go.y View 1 1 chunk +1 line, -1 line 0 comments Download
M src/cmd/gc/lex.c View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +1 line, -12 lines 0 comments Download
M src/cmd/gc/obj.c View 1 1 chunk +1 line, -1 line 0 comments Download
R src/cmd/gc/print.c View 1 1 chunk +0 lines, -625 lines 0 comments Download
M src/cmd/gc/range.c View 1 2 chunks +3 lines, -3 lines 0 comments Download
M src/cmd/gc/reflect.c View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 3 chunks +6 lines, -5 lines 0 comments Download
M src/cmd/gc/subr.c View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 16 7 chunks +6 lines, -946 lines 0 comments Download
M src/cmd/gc/typecheck.c View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 44 chunks +64 lines, -64 lines 0 comments Download
M src/cmd/gc/unsafe.c View 1 1 chunk +1 line, -1 line 0 comments Download
M src/cmd/gc/walk.c View 1 2 3 4 2 chunks +2 lines, -2 lines 0 comments Download
M src/pkg/fmt/fmt_test.go View 1 2 3 4 1 chunk +1 line, -1 line 0 comments Download
M src/pkg/reflect/all_test.go View 1 2 3 2 chunks +2 lines, -2 lines 0 comments Download
M test/ddd1.go View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +1 line, -1 line 0 comments Download
M test/fixedbugs/bug340.go View 1 2 3 1 chunk +1 line, -1 line 0 comments Download
M test/named1.go View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +1 line, -1 line 0 comments Download

Messages

Total messages: 15
lvd
Hello rsc@golang.org (cc: golang-dev@googlegroups.com), I'd like you to review this change to https://go.googlecode.com/hg/
13 years, 5 months ago (2011-10-19 20:18:23 UTC) #1
lvd
Hello rsc@golang.org (cc: golang-dev@googlegroups.com), Please take another look.
13 years, 5 months ago (2011-10-21 15:48:02 UTC) #2
lvd
i'm currently adding everything i find while working on 5296053, but don't let that stop ...
13 years, 5 months ago (2011-10-25 15:17:12 UTC) #3
rsc
Thanks very much. It's definitely an improvement. A bunch of small things below. I suspect ...
13 years, 5 months ago (2011-10-26 22:28:36 UTC) #4
lvd
Hello rsc@golang.org (cc: golang-dev@googlegroups.com), Please take another look.
13 years, 5 months ago (2011-10-28 10:57:50 UTC) #5
lvd
hm. linker not happy about Byte. yet, for the rest all done. http://codereview.appspot.com/5316043/diff/2003/src/cmd/gc/dcl.c File src/cmd/gc/dcl.c ...
13 years, 5 months ago (2011-10-28 11:02:57 UTC) #6
rsc
On Fri, Oct 28, 2011 at 04:02, <lvd@google.com> wrote: > because if you have type ...
13 years, 5 months ago (2011-10-28 14:41:26 UTC) #7
lvd
all tests pass, extra mode wasn't needed but we may revisit this later. i can ...
13 years, 5 months ago (2011-10-28 17:30:05 UTC) #8
lvd
On Fri, Oct 28, 2011 at 19:30, Luuk van Dijk <lvd@google.com> wrote: > all tests ...
13 years, 5 months ago (2011-10-28 17:45:42 UTC) #9
rsc
http://rsc.codereview.appspot.com/5316043/diff/4040/src/cmd/gc/fmt.c File src/cmd/gc/fmt.c (right): http://rsc.codereview.appspot.com/5316043/diff/4040/src/cmd/gc/fmt.c#newcode12 src/cmd/gc/fmt.c:12: // %L Line numbers Please add the types here. ...
13 years, 4 months ago (2011-10-31 15:04:45 UTC) #10
rsc
I think I understand all the formatting changes, and they look good. It seems like ...
13 years, 4 months ago (2011-10-31 15:17:53 UTC) #11
lvd
all done and fixed the ninit logic in stmtfmt. all tests pass http://rsc.codereview.appspot.com/5316043/diff/4040/src/cmd/gc/fmt.c File src/cmd/gc/fmt.c ...
13 years, 4 months ago (2011-10-31 15:39:55 UTC) #12
lvd
On 2011/10/31 15:39:55, lvd wrote: > all done and fixed the ninit logic in stmtfmt. ...
13 years, 4 months ago (2011-10-31 15:46:51 UTC) #13
rsc
LGTM!
13 years, 4 months ago (2011-10-31 17:06:26 UTC) #14
lvd
13 years, 4 months ago (2011-10-31 17:09:53 UTC) #15
*** Submitted as http://code.google.com/p/go/source/detail?r=cffdcf22fc7b ***

gc: clean up printing.

Got rid of all the magic mystery globals. Now
for %N, %T, and %S, the flags +,- and # set a sticky
debug, sym and export mode, only visible in the new fmt.c.
Default is error mode. Handle h and l flags consistently with
the least side effects, so we can now change
things without worrying about unrelated things
breaking.

fixes issue 2361

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

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