The Go programming language
Go to file
Andrei Vieru 1ab15fac22 fmt format verb %b bug
fmt.Printf("%b", int8(-1)) prints 64 ones instead of 8.
This happens only for signed integers (int8, in16 and int32). I guess it's because of the way the conversion between integer types works. From go spec: "Conversions between integer types. If the value is a signed quantity, it is sign extended to implicit infinite precision ....". And there are several conversions to int64 and uint64 in the fmt package. This pathch solves only half of the problem. On a 32 bit system, an fmt.Printf("%b", int(-1)) should still print 64 ones.

R=golang-dev, r
CC=golang-dev
https://golang.org/cl/891049
2010-04-12 10:20:06 -07:00
doc Update roadmap: delete many accomplishments 2010-04-09 13:22:05 -07:00
include Fix *l/*c -V flag segfault 2010-02-08 11:53:27 -08:00
lib codereview: Mention that deleting a CL is a use of 'hg change' in its header. 2010-04-10 01:53:43 -07:00
misc A test case for cgo //export. 2010-04-09 13:31:26 -07:00
pkg more description 2009-10-15 23:08:46 -07:00
src fmt format verb %b bug 2010-04-12 10:20:06 -07:00
test gc: make sure main.main has correct type 2010-04-11 14:51:35 -07:00
.hgignore runtime: add GOROOT and Version 2010-03-16 23:10:33 -07:00
.hgtags release.2010-03-30 part two 2010-03-31 12:38:54 +11:00
AUTHORS CLA: Andrei Vieru 2010-04-12 10:11:18 -07:00
CONTRIBUTORS CLA: Andrei Vieru 2010-04-12 10:11:18 -07:00
favicon.ico add a favicon plus a couple of hi-res versions of gordon 2009-10-26 10:13:07 -07:00
LICENSE Add an explicit patent grant to the Go license. 2010-01-25 15:39:32 -08:00
README add a README file, so that if someone finds a 2009-11-08 09:57:37 -08:00

This is the source code repository for the Go programming language.  

For documentation about how to install and use Go,
visit http://golang.org/ or load doc/install.html in your web browser.

After installing Go, you can view a nicely formatted
doc/install.html by running godoc --http=:6060
and then visiting http://localhost:6060/doc/install.html.

Unless otherwise noted, the Go source files are distributed
under the BSD-style license found in the LICENSE file.