gc: changes to export format in preparation for inlining.
string literals used as package qualifiers are now prefixed with '@'
which obviates the need for the extra ':' before tags.
first round of responses. will make the h flag for %#hN now. http://codereview.appspot.com/5129057/diff/4/src/pkg/go/types/gcimporter.go File src/pkg/go/types/gcimporter.go ...
14 years, 3 months ago
(2011-10-01 21:20:10 UTC)
#4
On Sat, Oct 1, 2011 at 14:20, <lvd@google.com> wrote: > .... will make the h ...
14 years, 3 months ago
(2011-10-01 22:54:03 UTC)
#5
On Sat, Oct 1, 2011 at 14:20, <lvd@google.com> wrote:
> .... will make the h flag for %#hN now.
Of course, it was never going to be that easy. exprfmt calls fmtprint,
which clears f->flags. that's a problem when exprfmt recurses, eg for
&MyStruct, the call to fmtprint %O for the & leaves the flags cleared. i
could change lib9/fmt/fmtprint.c to restore the flags on exit, (line 42)
because i wonder if that wasn't the intention. however, i suspect this may
change expected outputs all over cmd/../*.c. which needn't be disastrous.
Maybe it's time to bite the bullet and clean up the printing a bit b/c i've
wasted quite a bit of time walking through the call chains. basically we
have 3 usecases for printing: debugging the compiler, errors and
diagnostics (-m), and printing the export section.
i could either go over all formats and make the + flag print end-user
friendly, and # in export format, or make a global flag that takes the role
of the existing erroring and exporting (or keep those) and make them used
consistently all over the place.
maybe there's a pragmatic shortcut, but it's not going to be prettier.
/L
LGTM http://codereview.appspot.com/5129057/diff/30002/src/pkg/go/types/gcimporter.go File src/pkg/go/types/gcimporter.go (right): http://codereview.appspot.com/5129057/diff/30002/src/pkg/go/types/gcimporter.go#newcode145 src/pkg/go/types/gcimporter.go:145: // Declare creates a named object of the ...
14 years, 3 months ago
(2011-10-07 17:50:24 UTC)
#9
Issue 5129057: code review 5129057: gc: changes to export format in preparation for inlining.
(Closed)
Created 14 years, 3 months ago by lvd1
Modified 14 years, 3 months ago
Reviewers:
Base URL:
Comments: 50