Feature request: Pretty print big.Int and big.Float?
quenbyako opened this issue · 5 comments
quenbyako commented
cause stuff like
&big.Int{
neg: false,
abs: big.nat{
0x908f8474ea971baf,
},
}
does look too messy to be honest. Also, some default cool things like http response, rsa keys, etc. could be looking more cool (only most popular, much of default types should be printed explicitly)
k0kubun commented
Could you please specify both "the current output" and "the expected output" for each type of values? Otherwise it may end up being just something you didn't expect.
quenbyako commented
@k0kubun my idea is:
change current output:
&big.Int{
neg: false,
abs: big.nat{
0x908f8474ea971baf,
},
}
to expected output like
3.14159265359*10^12345 // digits after dot divider is fixed on like 16 digits, or i don't know, i like 16
Yes, this is not go-valid string, but, you know, prette printed time.Time
not too))))
quenbyako commented
Maybe, you have better representation of huge numbers, but i found this one as easy-to-read one