diff --git a/src/lib/fmt/format.go b/src/lib/fmt/format.go index 9099a163069..da8f9173297 100644 --- a/src/lib/fmt/format.go +++ b/src/lib/fmt/format.go @@ -5,10 +5,12 @@ package fmt /* + Raw formatter. See print.go for a more palatable interface. + f := fmt.New(); print f.d(1234).s("\n").str(); // create string, print it f.d(-1234).s("\n").put(); // print string - f.ud(^0).putnl(); // print string with automatic newline + f.ud(1<<63).putnl(); // print string with automatic newline */ // export Fmt, New; diff --git a/src/lib/fmt/print.go b/src/lib/fmt/print.go index db42c1e0d52..39500f44ae4 100644 --- a/src/lib/fmt/print.go +++ b/src/lib/fmt/print.go @@ -4,6 +4,11 @@ package fmt +/* + C-like printf, but because of reflection knowledge does not need + to be told about sizes and signedness (no %llud etc. - just %d). +*/ + import ( "fmt"; "reflect";