math/big: build Float.Format on top of Float.Append

Change-Id: I444eec24467f827caa5c88a1c5ae5bce92508b98
Reviewed-on: https://go-review.googlesource.com/3750
Reviewed-by: Alan Donovan <adonovan@google.com>
diff --git a/src/math/big/float_test.go b/src/math/big/float_test.go
index 3281f27..ec67a6d 100644
--- a/src/math/big/float_test.go
+++ b/src/math/big/float_test.go
@@ -205,7 +205,7 @@
 	} {
 		f := new(Float).SetUint64(want)
 		if got := f.Uint64(); got != want {
-			t.Errorf("got %d (%s); want %d", got, f.pstring(), want)
+			t.Errorf("got %d (%s); want %d", got, f.Format('p', 0), want)
 		}
 	}
 }
@@ -227,7 +227,7 @@
 			}
 			f := new(Float).SetInt64(want)
 			if got := f.Int64(); got != want {
-				t.Errorf("got %d (%s); want %d", got, f.pstring(), want)
+				t.Errorf("got %d (%s); want %d", got, f.Format('p', 0), want)
 			}
 		}
 	}
@@ -251,7 +251,7 @@
 			}
 			f := new(Float).SetFloat64(want)
 			if got, _ := f.Float64(); got != want {
-				t.Errorf("got %g (%s); want %g", got, f.pstring(), want)
+				t.Errorf("got %g (%s); want %g", got, f.Format('p', 0), want)
 			}
 		}
 	}
@@ -677,7 +677,7 @@
 		{append([]int{2, 1, 0} /* 7 */, []int{3, 1} /* 10 */ ...), "0x.88p5" /* 17 */},
 	} {
 		f := fromBits(test.bits...)
-		if got := f.pstring(); got != test.want {
+		if got := f.Format('p', 0); got != test.want {
 			t.Errorf("setBits(%v) = %s; want %s", test.bits, got, test.want)
 		}
 	}