From 1431634c5607631cf68bb453e5a6487800e4cf80 Mon Sep 17 00:00:00 2001 From: Robert Griesemer Date: Tue, 15 Mar 2016 15:14:11 -0700 Subject: [PATCH] cmd/guru: fix for prior submission (fix build) Accidentally submitted wrong file version in https://go-review.googlesource.com/20719. TBR: adonovan Change-Id: I362ded51cf9cef8cb22faf6a2334ce01678d9f4e Reviewed-on: https://go-review.googlesource.com/20742 Reviewed-by: Robert Griesemer --- cmd/guru/describe.go | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/cmd/guru/describe.go b/cmd/guru/describe.go index a42ca524..2bec552f 100644 --- a/cmd/guru/describe.go +++ b/cmd/guru/describe.go @@ -658,9 +658,8 @@ func constValString(v exact.Value) string { if v.Kind() == exact.Float { // In go1.5, go/constant floating-point values are printed // as fractions. Make them appear as floating-point numbers. - if f, ok := exact.Float64Val(v); ok { - return fmt.Sprintf("%g", f) - } + f, _ := exact.Float64Val(v) + return fmt.Sprintf("%g", f) } return v.String() }