mirror of
https://github.com/golang/go
synced 2024-11-12 10:30:23 -07:00
lib9: format %#04x, 0 as 0x0000 not 000000.
This matches Go's fmt.Printf instead of ANSI C's dumb rules. It makes the -S output from C liblink match Go's liblink. LGTM=minux R=minux CC=golang-codereviews https://golang.org/cl/112600043
This commit is contained in:
parent
8b20e7bb7e
commit
d4d50b5f01
@ -491,12 +491,6 @@ __ifmt(Fmt *f)
|
||||
if(fl & FmtApost)
|
||||
__needsep(&ndig, &grouping);
|
||||
}
|
||||
|
||||
/*
|
||||
* Zero values don't get 0x.
|
||||
*/
|
||||
if(f->r == 'x' || f->r == 'X')
|
||||
fl &= ~(ulong)FmtSharp;
|
||||
}
|
||||
for(w = f->prec; n < w && p > buf+3; n++){
|
||||
if((fl & FmtApost) && __needsep(&ndig, &grouping)){
|
||||
|
Loading…
Reference in New Issue
Block a user