1
0
mirror of https://github.com/golang/go synced 2024-10-04 13:11:22 -06:00
Commit Graph

1936 Commits

Author SHA1 Message Date
Stephen Ma
fd9a5d22c6 http: revised http Handler interface
R=rsc
CC=golang-dev
https://golang.org/cl/1993043
2010-09-29 14:30:12 +10:00
Russ Cox
6a1ea00d59 gotest: leave _testmain.go for "make clean" to clean up
R=r, brainman
CC=golang-dev
https://golang.org/cl/2297041
2010-09-28 22:59:16 -04:00
Ken Thompson
a2d2341e80 arm code gen error in unsign extend
R=rsc
CC=golang-dev
https://golang.org/cl/2295041
2010-09-28 18:12:46 -07:00
Russ Cox
2ccbf83b32 6l, 8l: elfsetstring is only for .shstrtab
Was also recording for .dynstrtab which made the
table run out of space and would have caused confusion
if the ELF code tried to refer to any of the strings.

R=r
CC=golang-dev
https://golang.org/cl/2288041
2010-09-28 15:18:02 -04:00
Russ Cox
00ffd59c1a gc: fix reflect table method receiver
Fixes #451.
Fixes #770.

R=ken2
CC=golang-dev
https://golang.org/cl/2207045
2010-09-28 13:43:50 -04:00
Russ Cox
05cc83bf4e various: appease the ubuntu gcc monster
Silence warnings about not checking
return values from read and write system calls.

R=r, r2
CC=golang-dev
https://golang.org/cl/2258045
2010-09-28 13:00:13 -04:00
Russ Cox
ec13ed1fce gc: insert semicolon at EOF if needed
R=ken2, gri
CC=golang-dev
https://golang.org/cl/2208053
2010-09-28 10:35:02 -04:00
Russ Cox
2d5e732c54 gc: eliminate duplicates in method table
Fixes #906.

R=ken2
CC=golang-dev
https://golang.org/cl/2279042
2010-09-27 14:09:10 -04:00
Russ Cox
7e92e1cbfa gc: fix non-canonical import error message
Fixes #1142.

R=ken2
CC=golang-dev
https://golang.org/cl/2218046
2010-09-27 12:59:26 -04:00
Russ Cox
9b62461a8f gc: allow select case expr = <-c
Fixes #1139.

R=ken2
CC=golang-dev
https://golang.org/cl/2194046
2010-09-27 12:04:21 -04:00
Russ Cox
b1f44a120f gc: improve error message for x \= 0
was
x.go:2: syntax error: unexpected $undefined

now
x.go:2: syntax error: unexpected \

R=ken2
CC=golang-dev
https://golang.org/cl/2267044
2010-09-24 17:09:31 -04:00
Robert Griesemer
daf64bf567 gofmt: don't substitute invalid positions with valid ones in rewrites
Fixes rewrite bug: 'f(x) -> f(0)' where functions "picked up" ... arguments.

R=rsc
CC=golang-dev
https://golang.org/cl/2279041
2010-09-24 12:58:08 -07:00
Russ Cox
1d315a8abd gc: printing of ...
R=ken2
CC=golang-dev
https://golang.org/cl/2218043
2010-09-24 12:29:20 -04:00
Russ Cox
2ee420fa5e ... changes
R=golang-dev, gri
CC=golang-dev
https://golang.org/cl/2273042
2010-09-24 11:55:48 -04:00
Russ Cox
75dd8fdb34 gc: ... changes
R=ken2, ken3
CC=golang-dev
https://golang.org/cl/2208047
2010-09-24 11:55:30 -04:00
Russ Cox
a2450c1456 cgo: bug fixes
* Add documentation about array arguments.  Fixes issue 1125.
* Do not interpret x, y := z, w as special errno form.  Fixes issue 952.
* Fix nested Go calls (brainman).  Fixes issue 907.

R=r
CC=golang-dev
https://golang.org/cl/2214044
2010-09-21 22:41:19 -04:00
Robert Griesemer
c20e024df3 godoc: default filter file name should be ""
R=rsc
CC=golang-dev
https://golang.org/cl/2241043
2010-09-20 16:19:17 -07:00
Ken Thompson
103d756663 loader fix
static init redo

R=rsc
CC=golang-dev
https://golang.org/cl/2254041
2010-09-20 14:23:25 -07:00
Luuk van Dijk
eb572e0174 6l/8l: emit DWARF frame info.
R=rsc, ken2, r
CC=golang-dev
https://golang.org/cl/2151044
2010-09-20 18:44:19 +02:00
Russ Cox
af12feb8d5 6l, 8l: clean up ELF code, fix NaCl
R=r
CC=golang-dev
https://golang.org/cl/2221042
2010-09-19 22:10:34 -04:00
Russ Cox
63623ba2d8 5l: avoid fixed buffers in list
R=ken2
CC=golang-dev
https://golang.org/cl/2204045
2010-09-19 19:44:52 -04:00
Ken Thompson
d348971103 add readonly flag to static initialization
R=rsc
CC=golang-dev
https://golang.org/cl/2187042
2010-09-16 16:42:38 -07:00
Robert Griesemer
b410be31b6 godoc: show "Last update" info for directory listings.
Use -timestamps=false flag to disable.

(This used to be shown on the front-page below the
build information with the old godoc. However, the
time stamps are directory-specific and should be
shown with the directory.)

R=rsc
CC=golang-dev
https://golang.org/cl/2233044
2010-09-16 13:45:40 -07:00
Russ Cox
d19fcd0784 gc: spell debug['u'] correctly
R=ken2
CC=golang-dev
https://golang.org/cl/2214042
2010-09-16 15:50:46 -04:00
Russ Cox
555f5b6b24 gc: make sure path names are canonical
R=ken2
CC=golang-dev
https://golang.org/cl/2209042
2010-09-16 15:37:57 -04:00
Robert Griesemer
fcb24e8c62 gofmt: add another exception to test cases
R=rsc
CC=golang-dev
https://golang.org/cl/2233043
2010-09-16 11:03:28 -07:00
Robert Griesemer
599f758d42 godoc: don't use quadratic algorithm to filter paths
R=rsc
CC=golang-dev
https://golang.org/cl/2212042
2010-09-16 10:40:07 -07:00
Eric Clark
b610a78b6e cgo: show preamble gcc errors
Fixes #1081

R=rsc
CC=golang-dev
https://golang.org/cl/2112046
2010-09-16 13:38:23 -04:00
Robert Griesemer
108f5c913c godoc: only show directories containing true package files
(ignore directories containing *.go files that don't
actually start with a package clause)

R=r
CC=golang-dev
https://golang.org/cl/2223041
2010-09-15 15:07:52 -07:00
Ken Thompson
abb73a4a86 fix line number printing
with //line directives.

R=rsc
CC=golang-dev
https://golang.org/cl/2224041
2010-09-15 14:32:09 -07:00
Robert Griesemer
7f0ddd682a godoc: better handling of deep directory trees
also: fix a logic error with filter use at startup

R=rsc
CC=golang-dev
https://golang.org/cl/2184044
2010-09-14 18:58:09 -07:00
Robert Griesemer
4398768b84 godoc: atomically update filter file
R=rsc
CC=golang-dev
https://golang.org/cl/2206041
2010-09-14 16:54:38 -07:00
Robert Griesemer
bce8f51b2b godoc: use correct delay time (bug fix)
R=rsc
CC=golang-dev
https://golang.org/cl/2201041
2010-09-14 13:59:45 -07:00
Robert Griesemer
b6f294def3 godoc documentation: fixed typo, more precise comment
R=iant
CC=golang-dev
https://golang.org/cl/2184042
2010-09-14 12:03:26 -07:00
Robert Griesemer
ec81b1259b godoc: better support for directory trees for user-defined
file systems provided via -path

R=rsc
CC=golang-dev
https://golang.org/cl/2182041
2010-09-14 11:16:36 -07:00
Russ Cox
d64a2bddf0 tabs
TBR=lvd
CC=golang-dev
https://golang.org/cl/2194041
2010-09-14 11:16:57 -04:00
Russ Cox
b7e9e9188a 6l, 8l: make etext accurate; introduce rodata, erodata.
Makes binaries work with 6cov again.

R=ken2
CC=golang-dev
https://golang.org/cl/2192041
2010-09-14 11:13:04 -04:00
Russ Cox
23bd214aee gc: implement new comparison rule
The new comparison rule was added to the spec by

	changeset:   5605:33abb649cb63
	user:        Robert Griesemer <gri@golang.org>
	date:        Thu Jun 03 16:55:50 2010 -0700
	files:       doc/go_spec.html
	description:
	go spec: Base comparison compatibility on assignment compatibility.

	Specifically:
	- Simplified definition of comparison compatibility and folded into
	  section on comparison operators since it's only used there.

	This is a small language change/cleanup. As a consequence:
	- An interface value may now be compared against a non-interface value.
	- Channels with opposite directions cannot be compared directly anymore
	  (per discussion with rsc).

	R=rsc, r, iant, ken2
	CC=golang-dev
	https://golang.org/cl/1462041

but never implemented.

Fixes #1070.

R=ken2
CC=golang-dev
https://golang.org/cl/2116047
2010-09-13 15:42:47 -04:00
Russ Cox
c3900387db gc: bug306
Fixes #1040.

R=ken2
CC=golang-dev
https://golang.org/cl/2132047
2010-09-13 15:42:14 -04:00
Scott Lawrence
25c8d4e932 goinstall: warn when http:// is found at beginning of package name
Fixes #860.

R=golang-dev, adg1, rsc, adg
CC=golang-dev
https://golang.org/cl/2124046
2010-09-13 12:59:59 +10:00
Alex Brainman
77a70ddb7b gc: fix symbol table generation on windows
gc records full, '/' delimited, filenames now.

R=rsc
CC=golang-dev
https://golang.org/cl/1962042
2010-09-12 18:07:13 +10:00
Russ Cox
f47d403cb4 gc: make string x + y + z + ... + w efficient
1 malloc per concatenation.

R=ken2
CC=golang-dev
https://golang.org/cl/2124045
2010-09-12 00:53:04 -04:00
Russ Cox
698fb4f192 6g, 6l, 8g, 8l: move read-only data to text segment
Changing 5g and 5l too, but it doesn't work yet.

R=ken2
CC=golang-dev
https://golang.org/cl/2136047
2010-09-12 00:17:44 -04:00
Russ Cox
be443ee8bc 5g: register allocation bugs
Fixes #1099.

R=ken2, r
CC=golang-dev
https://golang.org/cl/2147047
2010-09-12 00:06:45 -04:00
Russ Cox
0acb63769c gc: const nil bug
Fixes #1073.

R=ken2
CC=golang-dev
https://golang.org/cl/2169043
2010-09-11 15:47:56 -04:00
Rob Pike
0aa2317096 arm: work around reg allocator bug in 5g, in two parts.
1) hack regalloc to leave R9 (m) and R10 (g) alone.
the real fix is tricker, but this gets us running
2) fix up the few places in the package sources that
the shortage of registers affects, by simplifying
some expressions.

all of this should be reverted when the right fix is in.

Fixes #1084.

R=rsc
CC=golang-dev
https://golang.org/cl/2132046
2010-09-10 20:55:29 -07:00
Joe Poirier
41e5a78441 windows: disable unimplemented tests
Add windows NOTEST list to pkg make file.
5a make file. the change removes a space
character that was included when appending
an extension to TARG.

R=brainman, rsc
CC=golang-dev
https://golang.org/cl/2140046
2010-09-10 14:05:57 -04:00
Dan Sinclair
122f3980c7 ld: handle quoted spaces in package path
Fixes #1087.

R=rsc
CC=golang-dev
https://golang.org/cl/2172041
2010-09-10 13:59:20 -04:00
Russ Cox
2cda191aef 6c, 8c: show line numbers in -S output
R=ken2
CC=golang-dev
https://golang.org/cl/2107047
2010-09-10 11:53:51 -04:00
Russ Cox
82ee481dfc gc: remove &[10]int -> []int conversion
Fixes #829.

R=ken2
CC=golang-dev
https://golang.org/cl/2124044
2010-09-10 11:53:27 -04:00
Robert Griesemer
0eb0afde9a fix build
R=rsc, ken2
CC=golang-dev
https://golang.org/cl/2118050
2010-09-09 14:42:49 -07:00
Russ Cox
1678dcc378 gc: more accurate line numbers for ATEXT
and other begin and end of function code

R=ken2
CC=golang-dev
https://golang.org/cl/2158044
2010-09-09 17:11:51 -04:00
Joe Poirier
e21b3a40ac build: test for _WIN32, not _MINGW32
Use OS rather than compiler specific flag the same way that
__FreeBSD__, __APPLE__, __OpenBSD__, and __linux__ are used.

_WIN32 is defined by GCC (and others) on windows for Win32
and Win64 applications. _WIN32 is set by default for several
other windows based compilers: DMC, MSVC, Intel, Watcom, LCC.

Although the change is for consistency, it allows the Go tools
to be compiled with non-Mingw GCC distributions and non-GCC
compilers that support the GCC extensions.

R=rsc, brainman, vcc
CC=golang-dev
https://golang.org/cl/2168043
2010-09-08 22:20:35 -04:00
Scott Lawrence
fce222a95b gc: implement new slice spec
Fixes #382.

R=gri, cw, r, rsc
CC=golang-dev
https://golang.org/cl/1957045
2010-09-08 22:20:29 -04:00
Andrew Gerrand
e1b79b712c cgo: add typedef for uintptr in generated headers
Fixes #1046.

R=rsc, iant
CC=golang-dev
https://golang.org/cl/2102043
2010-09-09 09:24:53 +10:00
Russ Cox
5baaa490d6 gc: better printing of named constants, func literals
R=ken2
CC=golang-dev
https://golang.org/cl/2121045
2010-09-08 10:12:56 -04:00
Robert Griesemer
889377c572 godoc: moved package directory support code into separate file
- in prep. for some restructuring to be able to better deal
  with very large file systems
- moved a utility function into index.go
- no functionality changes, only code reorg.

R=r, adg1
CC=golang-dev
https://golang.org/cl/2098044
2010-09-07 17:21:00 -07:00
Russ Cox
2eb00d57b4 cgo: silence warning for C call returning const pointer
Fix suggested by Albert Strasheim.

R=adg
CC=golang-dev
https://golang.org/cl/2154041
2010-09-07 09:54:20 -04:00
Russ Cox
a41db4318d goinstall: assume go binaries are in path
(Following new convention.)

Fixes #1063.

R=adg
CC=golang-dev
https://golang.org/cl/2115042
2010-09-03 15:37:45 -04:00
Russ Cox
1cb951d994 gc: appease bison version running on FreeBSD builder
R=ken2
CC=golang-dev
https://golang.org/cl/2141042
2010-09-02 14:31:39 -04:00
Russ Cox
dea283750b gc: fix spurious syntax error
Fixes #1071.

R=ken2
CC=golang-dev
https://golang.org/cl/2136043
2010-09-02 14:16:01 -04:00
Scott Lawrence
ebe837d6eb goinstall: added -a flag to mean "all remote packages"
Fixes #897.

goinstall -a can be used to reinstall all packages after an upgrade
goinstall -a -u can be used to update all package
A history of remote package installs is stored in $GOROOT/goinstall.log

R=rsc, adg
CC=golang-dev
https://golang.org/cl/1947041
2010-09-02 13:48:28 -04:00
Alex Brainman
b05679cdd6 8l: suppress emitting DWARF in Windows PE.
Fixes #1064.

R=rsc, lvd, vcc
CC=golang-dev
https://golang.org/cl/2104042
2010-09-02 17:00:24 +10:00
Luuk van Dijk
728003e340 6l/8l: emit DWARF in macho.
R=rsc, r, ken2
CC=golang-dev
https://golang.org/cl/2128041
2010-09-01 21:54:28 +02:00
Luuk van Dijk
b433552ebc 8l: emit DWARF in ELF.
R=rsc, r, ken2
CC=golang-dev
https://golang.org/cl/2004046
2010-08-30 22:20:38 +02:00
Christian Himpel
5c603dbb75 build: remove unnecessary references to GOBIN and GOROOT
All scripts and makefiles assume that GOBIN is correctly set
in PATH.

R=rsc
CC=golang-dev
https://golang.org/cl/2043041
2010-08-30 15:40:56 -04:00
Russ Cox
9686ab2da9 8g: use FCHS, not FMUL, for minus float
Fixes #1052.

R=ken2
CC=golang-dev
https://golang.org/cl/2055041
2010-08-27 14:02:00 -04:00
Kyle Consalus
e24910d09b gc: brace nit from last review
R=rsc
CC=golang-dev
https://golang.org/cl/1997045
2010-08-26 18:46:56 -04:00
Robert Griesemer
c606b964a0 go/typechecker: 2nd step towards augmenting AST with full type information.
- refine/define Scope, Object, and Type structures
  (note: scope.go has the addition of types, the rest is only re-organized
  for better readability)
- implemented top-level of type checker:
  resolve global type declarations (deal with double decls, cycles, etc.)
- temporary hooks for checking of const/var declarations, function/method bodies
- test harness for fine-grained testing (exact error locations)
  with initial set of tests

This is a subset of the code for easier review.

R=rsc
CC=golang-dev
https://golang.org/cl/1967049
2010-08-26 14:36:13 -07:00
Kyle Consalus
4d903504b3 runtime: special case copy, equal for one-word interface values
Based on the observation that a great number of the types that
are copied or compared in interfaces, maps, and channels are
word-sized, this uses specialized copy and equality functions
for them that use a word instead of 4 or 8 bytes. Seems to yield
0-6% improvements in performance in the benchmarks I've run.
For example, with the regexp benchmarks:

Before:
regexp.BenchmarkLiteral   500000       3.26 µs/op
regexp.BenchmarkNotLiteral    100000      13.67 µs/op
regexp.BenchmarkMatchClass    100000      18.72 µs/op
regexp.BenchmarkMatchClass_InRange    100000      20.04 µs/op
regexp.BenchmarkReplaceAll    100000      27.85 µs/op

After:
regexp.BenchmarkLiteral   500000       3.11 µs/op
regexp.BenchmarkNotLiteral    200000      13.29 µs/op
regexp.BenchmarkMatchClass    100000      17.65 µs/op
regexp.BenchmarkMatchClass_InRange    100000      18.49 µs/op
regexp.BenchmarkReplaceAll    100000      26.34 µs/op

R=rsc
CC=golang-dev
https://golang.org/cl/1967047
2010-08-26 13:32:40 -04:00
Russ Cox
dbc6d75315 goinstall: use https for Google Code checkouts
This way, if you later want to check things in,
you can (with appropriate authorization).
Using plain http leads to the cryptic error
abort: HTTP Method Not Allowed.

R=r
CC=golang-dev
https://golang.org/cl/1983050
2010-08-25 18:08:16 -04:00
Russ Cox
423e410258 gotest: allow make test of cgo packages (without make install)
R=r
CC=golang-dev, stevvooe
https://golang.org/cl/1995051
2010-08-25 18:00:42 -04:00
Russ Cox
15f336b675 build: let pkg/Makefile coordinate building of Go commands
Commands written in Go depend on Go packages, so they
cannot be built by src/cmd/make.bash.  They have been
built by src/make.bash after all the packages are done, but
we want to be able to use cgo (written in Go) during the build
of package net.  To make this possible, build the commands
from src/pkg/Makefile instead of src/make.bash, so that they
are included in the package dependency analysis.

R=r
CC=golang-dev
https://golang.org/cl/1972046
2010-08-25 17:54:10 -04:00
Russ Cox
2aa77c6b93 gotest: remove lingering references to $GOBIN
(Assumed to be in $PATH.  all.bash ensures that
during the main build and the user must ensure it
when running commands like gotest or gomake
by hand.  This belonged in the earlier CL but I missed it.)

R=r
CC=golang-dev
https://golang.org/cl/1967048
2010-08-24 21:56:32 -04:00
Russ Cox
aafe474ec9 build: $GOBIN defaults to $GOROOT/bin
R=r
CC=golang-dev
https://golang.org/cl/1982049
2010-08-24 20:00:33 -04:00
Russ Cox
b1311cbc93 gc: fix parenthesization check
Cannot use paren field in Node because all
instances of a given symbol name use the same Node.

Fixes #1022.

R=ken2
CC=golang-dev
https://golang.org/cl/2015043
2010-08-23 23:10:25 -04:00
Ken Thompson
96cbdd62b6 better job on 2007043
better registerization

R=rsc
CC=golang-dev
https://golang.org/cl/1955049
2010-08-23 12:38:15 -07:00
Ken Thompson
3dc3ef4cf7 attempt to gete better registeration
from the builtin structures (strings,
slices, interfaces)

R=rsc
CC=golang-dev
https://golang.org/cl/2007043
2010-08-19 18:18:51 -07:00
Robert Griesemer
3112bb0727 go/ast, gofmt: facility for printing AST nodes
go/ast: implement Fprint and print functions to
print AST nodes

gofmt: print AST nodes by setting -ast flag

R=rsc, r
CC=golang-dev
https://golang.org/cl/1981044
2010-08-19 09:39:35 -07:00
Eric Clark
95fa16a892 cgo: add C.GoStringN
Function to create a GoString with a known length so it can contain NUL
bytes anywhere in the string. Some C libraries have strings like this.

R=rsc
CC=golang-dev
https://golang.org/cl/2007042
2010-08-18 22:29:05 -04:00
Luuk van Dijk
ca9098ee94 Dwarf output for 6l.
Part 1, general scaffolding and pc/lc sections.

R=rsc, r, ken2
CC=golang-dev
https://golang.org/cl/1987042
2010-08-18 16:53:22 +02:00
Russ Cox
da392d9136 build: no required environment variables
R=adg, r, PeterGo
CC=golang-dev
https://golang.org/cl/1942044
2010-08-18 10:08:49 -04:00
Russ Cox
31339c3224 cgo: fix build: use $GCC, not $CC
I'm not sure there's a better way.
Cgo is juggling two different C compilers.

Fixes #1008.

R=iant
CC=golang-dev
https://golang.org/cl/1972044
2010-08-18 10:03:01 -04:00
Ken Thompson
5b0c317c9c code optimization on slices
R=rsc
CC=golang-dev
https://golang.org/cl/1942043
2010-08-13 19:39:36 -07:00
Ken Thompson
3efb4c3b63 fix bounds check in error recovery
(thanks to avp@mit.edu)

R=rsc
CC=golang-dev
https://golang.org/cl/1998041
2010-08-13 14:30:18 -07:00
Robert Griesemer
1f9dfa294f go AST: First step towards augmenting AST with full type information.
- change ast.Ident back to contain the name and adjust all dependent code
- identifier object information will be added again through an optional
  typechecker phase (in the works).
- remove tracking of scopes in parser - it's easier to do this in a separate
  phase (in the works)
- in godoc, generate popup info table directly instead of through a formatter
  for simpler data flow (at the expense of a little bit more code)

Runs all tests.

As a result of this change, the currently shown popup information
(const, var, type, func, followed by identifier name) will not be
shown anymore temporarily.

R=rsc
CC=golang-dev
https://golang.org/cl/1994041
2010-08-13 10:42:18 -07:00
Robert Griesemer
10ae88f4ab partial correction for CL 1983043: fix various godoc-related regexp calls
R=rsc
CC=golang-dev
https://golang.org/cl/1987041
2010-08-12 11:28:50 -07:00
Rob Pike
d31ee536e8 update the tree to use the new regexp methods
R=rsc
CC=golang-dev
https://golang.org/cl/1983043
2010-08-12 16:48:41 +10:00
Russ Cox
1d77ff5b6b 6g, 8g: handle slice by sub-word-sized index (uint8, int8, uint16, int16)
R=ken2
CC=golang-dev
https://golang.org/cl/1960042
2010-08-11 22:27:47 -07:00
Russ Cox
26dde76cee gopack: handle long lines in export data
Also, if the header is bad, exit with a non-zero status.

Other calls to Brdline in the tree, by category:

Reading symbol name from object file:
./cmd/5l/obj.c:486: 		name = Brdline(f, '\0');
./cmd/6l/obj.c:535: 		name = Brdline(f, '\0');
./cmd/8l/obj.c:564: 		name = Brdline(f, '\0');
./libmach/sym.c:292: 		cp = Brdline(bp, '\0');

Reading archive header line (fixed, short):
./cmd/gc/lex.c:287: 	if((a = Brdline(b, '\n')) == nil)
./cmd/gc/lex.c:303: 	if((p = Brdline(b, '\n')) == nil)

Reading object file header line (fixed, short):
./cmd/ld/lib.c:421: 	line = Brdline(f, '\n');

Reading undefined symbol list (unused code):
./cmd/ld/lib.c:773: 	while((l = Brdline(b, '\n')) != nil){

Implementing Brdstr:
./libbio/brdstr.c:36: 		p = Brdline(bp, delim);

The symbol names ones will cause a problem loudly if they
fail: they'll error out with symbol name too long.  This means
that you can't define an enormous struct without giving the
type a name and then stick it in an interface, because the
type's symbol name will be too long for the object file.
Since this will be a loud failure instead of a silent one,
I'm willing to wait until it comes up in practice.

R=r
CC=golang-dev
https://golang.org/cl/1982041
2010-08-11 22:17:20 -07:00
Russ Cox
14e0df34fd 5g, 8g: dead code (already removed from 6g)
R=ken2
CC=golang-dev
https://golang.org/cl/1983041
2010-08-11 21:58:29 -07:00
Robert Griesemer
d75074974a gofmt: if a semicolon is found unexpectedly, report detailed cause
go/scanner: return information on semicolon (real or inserted) when
	    found in source
go/parser:  better error message when a semicolon is found unexpectedly

For instance, if an unexpected semicolon is found that was automatically
inserted, the parser error message is now:

    "expected '}', found newline"

Fixes #1006.

R=rsc
CC=golang-dev
https://golang.org/cl/1936044
2010-08-11 21:25:52 -07:00
Russ Cox
a9a62eef6b gc: bug302
Fixed by http://code.google.com/p/go/source/detail?r=d1f41e20a90e
This just adds a test and checks the return value of Bprint.

R=ken2
CC=golang-dev
https://golang.org/cl/1949042
2010-08-10 17:39:38 -07:00
Robert Griesemer
d754309489 godoc: report Status 404 if a pkg or file is not found
Fixes #1005.

R=rsc, r
CC=golang-dev
https://golang.org/cl/1935041
2010-08-10 09:52:02 -07:00
Scott Lawrence
4368a78755 gopack documentation: fixed typo
(Removed extraneous "program".)

R=golang-dev, r
CC=golang-dev
https://golang.org/cl/1950041
2010-08-10 18:01:00 +10:00
Scott Lawrence
d5cfb3b3d5 goinstall docs: fixed typos
(Added mising closing quotes.)

R=golang-dev, gri
CC=golang-dev
https://golang.org/cl/1902049
2010-08-09 10:45:20 -07:00
Kai Backman
df88fc6109 arm: bugfixes and syscall
- integer divide by zero raises panic
- float comparisons involving NaNs work
- syscall interface actually handles return
  values and errno correctly.

R=rsc, bradfitzpatrick
CC=golang-dev
https://golang.org/cl/1847047
2010-08-06 16:57:49 -07:00
Russ Cox
e473f42b2d amd64: use segment memory for thread-local storage
Returns R14 and R15 to the available register pool.
Plays more nicely with ELF ABI C code.
In particular, our signal handlers will no longer crash
when a signal arrives during execution of a cgo C call.

Fixes #720.

R=ken2, r
CC=golang-dev
https://golang.org/cl/1847051
2010-08-04 17:50:22 -07:00
Robert Griesemer
03f42934c1 gofmt/go/parser: strengthen syntax checks
- don't allow parenthesized receiver base types or anonymous fields
- fixed a couple of other omissions
- adjusted gofmt test script
- removed several TODOs

R=rsc
CC=golang-dev
https://golang.org/cl/1897043
2010-08-04 17:21:02 -07:00
Alex Brainman
12576f9e70 goinstall: check for error from exec.*Cmd.Wait() before using its result
R=golang-dev, rsc
CC=golang-dev
https://golang.org/cl/1923043
2010-08-04 17:18:57 -07:00
Christian Himpel
6b8ec5c572 cgo: generate correct multiple return value function invocations
Fixes #967.

R=rsc
CC=golang-dev
https://golang.org/cl/1855051
2010-08-04 17:15:04 -07:00
Robert Griesemer
a6449b66a4 gofmt: make code more readable by avoiding redeclaration
R=r
CC=golang-dev
https://golang.org/cl/1910045
2010-08-03 23:39:01 -07:00
Rob Pike
e45b58fe96 os: change the type of permissions argument for Open etc. to uint32.
Besides being more correct, it protects against people accidentally
exchanging the permission and open mode arguments to Open.

R=rsc
CC=golang-dev
https://golang.org/cl/1904045
2010-08-04 08:34:52 +10:00
Kai Backman
311973ea56 arm: remove old qemu dependency from gotest
R=rsc
CC=golang-dev
https://golang.org/cl/1678063
2010-08-03 13:03:40 -07:00
Russ Cox
3f19d8ae8d gc: empty select
R=ken2
CC=golang-dev
https://golang.org/cl/1871057
2010-08-03 01:07:57 -07:00
Russ Cox
585eae3bce gc: bug301
Fixes #990.

R=ken2
CC=golang-dev
https://golang.org/cl/1742055
2010-08-03 01:07:40 -07:00
Russ Cox
c6cb303a8a gc: bug299, bug300
R=ken2
CC=golang-dev
https://golang.org/cl/1731057
2010-08-03 00:53:32 -07:00
Russ Cox
9bac9d23d3 gc: index bounds tests and fixes
move constant index checking to front end
x[2:1] is a compile-time error now too

R=ken2
CC=golang-dev
https://golang.org/cl/1848056
2010-08-03 00:26:02 -07:00
Kai Backman
8d76a15122 arm: bugfixes (stack clobbering, indices)
also changed zerodivide to output "BUG"

R=rsc
CC=golang-dev
https://golang.org/cl/1871055
2010-07-30 10:37:51 +03:00
Joe Poirier
b57ffae094 cov and prof: implement windows version (just function stubs and build mods)
R=brainman, rsc
CC=golang-dev
https://golang.org/cl/1676054
2010-07-30 11:47:11 +10:00
Russ Cox
491a3ca5b7 gc: fix SIGBUS
R=ken2
CC=golang-dev
https://golang.org/cl/1906042
2010-07-28 18:21:50 -07:00
Kai Backman
fa4da33315 arm: minor bugfixes.
R=rsc
CC=golang-dev
https://golang.org/cl/1692057
2010-07-28 15:58:35 +03:00
Russ Cox
f930d28164 5g: fix build
R=ken2
CC=golang-dev
https://golang.org/cl/1893042
2010-07-27 13:43:58 -07:00
Russ Cox
711f075987 gc: include signal.h (fix build)
R=ken2
CC=golang-dev
https://golang.org/cl/1871049
2010-07-26 18:41:36 -07:00
Robert Griesemer
0b133d8ac1 godoc: accept '.', '!', and '?' as end of first sentence of package documentation
R=rsc
CC=golang-dev
https://golang.org/cl/1875049
2010-07-26 17:34:40 -07:00
Russ Cox
f20c2e1cf5 gc: more crash avoidance
Fixes #961.
Fixes #962.

R=ken2
CC=golang-dev
https://golang.org/cl/1903043
2010-07-26 17:34:17 -07:00
Russ Cox
9a442211c6 6l: more invalid input files
Fixes #963.
Fixes #964.

R=r
CC=golang-dev
https://golang.org/cl/1874045
2010-07-26 17:34:02 -07:00
Russ Cox
b49561d884 gc: graceful exit on seg fault
R=ken2
CC=golang-dev
https://golang.org/cl/1882043
2010-07-26 16:52:51 -07:00
Robert Griesemer
4188504f38 godoc: display synopses for all packages that have some kind of documentation.
Fixes #953.

R=rsc
CC=golang-dev
https://golang.org/cl/1862046
2010-07-26 15:27:42 -07:00
Russ Cox
607eaea456 gc: fix smaller-than-pointer-sized receivers in interfaces
Fixes #812.

R=ken2
CC=golang-dev
https://golang.org/cl/1904041
2010-07-26 15:25:10 -07:00
Russ Cox
7b240e8135 gc: import dot shadowing bug
R=ken2
CC=golang-dev
https://golang.org/cl/1873047
2010-07-26 14:21:39 -07:00
Andrew Gerrand
f656a87697 prof: fix typo in usage string
Fixes #948.

R=rsc
CC=golang-dev
https://golang.org/cl/1890043
2010-07-26 14:46:53 +10:00
Russ Cox
fa3d86ca39 libmach: correct handling of .5 files with D_REGREG addresses
undo workaround in gc

Fixes #943.

R=kaib
CC=golang-dev
https://golang.org/cl/1889041
2010-07-22 09:00:34 -07:00
Russ Cox
2cc9d339e6 fix build
bug introduced in https://golang.org/cl/1886043

R=r
CC=golang-dev
https://golang.org/cl/1848047
2010-07-22 08:55:56 -07:00
Micah Stetson
d1e7cffe6c gotest: fix the glob pattern in the top-of-file comment
R=golang-dev, adg
CC=golang-dev
https://golang.org/cl/1847042
2010-07-22 10:07:26 +10:00
Russ Cox
916f896a3b ld: various bug fixes
Fixes #937.
Fixes #938.
Fixes #939.
Fixes #940.

R=r
CC=golang-dev
https://golang.org/cl/1886043
2010-07-21 13:44:49 -07:00
Kai Backman
47b6400556 arm: fix build by disabling list copying optimization for 5g.
R=rsc
CC=golang-dev
https://golang.org/cl/1697053
2010-07-21 14:14:21 +03:00
Russ Cox
0decedf636 gc: various bug fixes
Fixes #935.
Fixes #936.
Fixes #941.

R=ken2
CC=golang-dev
https://golang.org/cl/1867042
2010-07-20 23:45:33 -07:00
Ken Thompson
f6b93ab432 change floating literal normalization
from word-oriented to bit-oriented.
this will increase fp literal precision
by up to a full word.

R=rsc
CC=golang-dev
https://golang.org/cl/1859044
2010-07-19 16:10:46 -07:00
Russ Cox
2d6ae385e1 linux/386: use Xen-friendly ELF TLS instruction sequence
Fixes #465.

R=iant
CC=golang-dev
https://golang.org/cl/1665051
2010-07-17 16:54:03 -07:00
Ken Thompson
95b93c28e3 1. got 29 (Mpscale) more bits of precision
out of floating constant multiply
2. added rounding code to "const fix=float"
to allow up to 29 (Mpscale) bits of
slop and still get an exact fixed constant.

fixes #931

R=rsc
CC=golang-dev
https://golang.org/cl/1692055
2010-07-17 16:32:40 -07:00
Russ Cox
b693847ea8 gc: print error detail about failure to open import
R=ken2
CC=golang-dev
https://golang.org/cl/1872041
2010-07-16 21:38:51 -07:00
Russ Cox
e692977af3 5l, 6l, 8l: reject invalid input files
Fixes #925.
Fixes #926.
Fixes #927.
Fixes #928.
Fixes #929.
Fixes #930.

R=r
CC=golang-dev
https://golang.org/cl/1752044
2010-07-16 16:16:17 -07:00
Rob Pike
8519134b98 fix typo in lex.c comment
R=rsc
CC=golang-dev
https://golang.org/cl/1862044
2010-07-16 15:08:31 -07:00
Ken Thompson
19d7fc4026 change line pragma from
//line number file
to
	//line file:number

R=rsc
CC=golang-dev
https://golang.org/cl/1868041
2010-07-16 13:34:36 -07:00
Ian Lance Taylor
8a95821694 cgo: If CC is set in environment, use it rather than "gcc".
R=rsc
CC=golang-dev
https://golang.org/cl/1842042
2010-07-16 11:01:04 -07:00
Ken Thompson
444066e56d interpret lines that look like
//line 10 units.y
which is equiv to c
	#line 10 units.y
the purpose is to generate diagnostics
that correctly point to preprocessed source.

R=rsc
CC=golang-dev
https://golang.org/cl/1863042
2010-07-15 20:21:33 -07:00
Russ Cox
4c0de303ce gc: bug294
Fixes #800.

R=ken2
CC=golang-dev
https://golang.org/cl/1855043
2010-07-15 16:42:32 -07:00
Russ Cox
ece6a8c549 gc: bug293
Fixes #846.

R=ken2
CC=golang-dev
https://golang.org/cl/1862042
2010-07-15 16:14:06 -07:00
Russ Cox
cdb446feb5 gc: bug292
Fixes #843.

R=ken2
CC=golang-dev
https://golang.org/cl/1729051
2010-07-15 16:13:47 -07:00
Russ Cox
b2a919fc29 gc: issue 894
Fixes #894.

R=ken2
CC=golang-dev
https://golang.org/cl/1701051
2010-07-15 15:25:32 -07:00
Russ Cox
31c07dfddf gc: issue 901
Fixes #901.

R=ken2
CC=golang-dev
https://golang.org/cl/1674049
2010-07-15 15:22:51 -07:00
Russ Cox
08a263a991 gc: bug291
Fixes #915.

R=ken2
CC=golang-dev
https://golang.org/cl/1856042
2010-07-15 15:17:42 -07:00
Russ Cox
691d765121 gc: bug274
R=ken2
CC=golang-dev
https://golang.org/cl/1742044
2010-07-15 15:05:56 -07:00
Russ Cox
17f90c68c6 gc: fix handling of types inside function bodies
Fixes #849.
Fixes #920.

R=ken2
CC=golang-dev
https://golang.org/cl/1841042
2010-07-15 14:25:50 -07:00
Russ Cox
0432f289f7 cgo: various bug fixes
* remember #defined names, so that C.stdout can refer
  to the real name (on OS X) __stdoutp.
* better handling of #defined constant expressions
* allow n, err = C.strtol("asdf", 0, 123) to get errno as os.Error
* write all output files to current directory
* don't require gcc output if there was no input

Fixes #533.
Fixes #709.
Fixes #756.

R=r
CC=dho, golang-dev, iant
https://golang.org/cl/1734047
2010-07-14 17:17:53 -07:00
Rob Pike
c9f83372d8 add missing argument to usage message.
Fixes #912.

R=rsc
CC=golang-dev
https://golang.org/cl/1819041
2010-07-12 16:31:51 -07:00
Robert Griesemer
d87f7e2392 gofmt: update test script
R=r
CC=golang-dev
https://golang.org/cl/1791041
2010-07-09 13:03:25 -07:00
Russ Cox
44eaaaaa78 ld: fix handling of "". names in #pragma dynimport/dynexport
Fixes #728.

R=r
CC=golang-dev
https://golang.org/cl/1706053
2010-07-01 21:48:13 -07:00
Russ Cox
81c3e8cabc gc: implement new len spec, range bug fix, optimization
Fixes #885.

R=ken2
CC=golang-dev
https://golang.org/cl/1680048
2010-07-01 18:04:25 -07:00
Rob Pike
38f1231f3e strings and bytes.Split: make count of 0 mean 0, not infinite.
Use a count of -1 for infinity.  Ditto for Replace.

R=rsc
CC=golang-dev
https://golang.org/cl/1704044
2010-07-01 14:08:14 -07:00
Russ Cox
285312a05c 6l: drop confusing comment
R=ken2
CC=golang-dev
https://golang.org/cl/1693047
2010-07-01 12:51:00 -07:00
Russ Cox
e5009e29ea 6a: assemble CMPPD as 6l expects
libmach: disassemble CMPPD as 6a expects

R=ken2
CC=Charlie Dorian, golang-dev
https://golang.org/cl/1704046
2010-07-01 12:36:29 -07:00
Russ Cox
bf10982739 6l: implement MOVLQZX as "mov", not "movsxd"
(Here, quoted strings are the official AMD names.)

The amd64 "movsxd" instruction, when invoked
with a 64-bit REX prefix, moves and sign extends
a 32-bit value from register or memory into a
64-bit register.  6.out.h spells this MOVLQSX.

6.out.h also includes MOVLQZX, the zero extending
version, which it implements as "movsxd" without
the REX prefix.  Without the REX prefix it's only sign
extending 32 bits to 32 bits (i.e., not doing anything
to the bits) and then storing in a 32-bit register.
Any write to a 32-bit register zeros the top half of the
corresponding 64-bit register, giving the advertised effect.
This particular implementation of the functionality is
non-standard, because an ordinary 32-bit "mov" would
do the same thing.

Because it is non-standard, it is often mishandled or
not handled by binary translation tools like valgrind.
Switching to the standard "mov" makes the binaries
work better with those tools.

It's probably useful in 6c and 6g to have an explicit
instruction, though, so that the intent of the size
change is clear.  Thus we leave the concept of MOVLQZX
and just implement it by the standard "mov" instead of
the non-standard 32-bit "movsxd".

Fixes #896.

R=ken2
CC=golang-dev
https://golang.org/cl/1733046
2010-07-01 12:18:35 -07:00
Gustavo Niemeyer
ae33032893 goinstall: support for Bazaar+Launchpad
With these changes, goinstall is now able to use branches
maintained with Bazaar located in Launchpad.

Project aliases such as /project and /project/series are
supported in addition to specific user or team branches
such as /~user/project/branch.  Temporary branches under
the +junk special project are also supported.

As a curious side effect, since Launchpad is able to import
code from other locations, they can be indirectly
accessible too if desired.

R=rsc
CC=golang-dev
https://golang.org/cl/1699050
2010-06-30 23:33:49 -07:00
Russ Cox
489494cac3 cgo: use slash-free relative paths for .so references
The Makefile and cgo now rewrite / to _ when creating the path.
The .so for gosqlite.googlecode.com/hg/sqlite is named
cgo_gosqlite.googlecode.com_hg_sqlite.so, and then 6l and 8l
both include a default rpath of $GOROOT/pkg/$GOOS_$GOARCH.
This should make it easier to move binaries from one system
to another.

Fixes #857.

R=iant, r
CC=golang-dev
https://golang.org/cl/1700048
2010-06-30 23:31:27 -07:00
Russ Cox
7c9ed7946c 8g: out of register bug fix
Fixes #868.

R=ken2
CC=golang-dev
https://golang.org/cl/1695049
2010-06-30 20:45:50 -07:00
Russ Cox
ed39c764b8 gc: do not crash on bad [...]T
Fixes #879.

R=ken2
CC=golang-dev
https://golang.org/cl/1678048
2010-06-30 20:34:31 -07:00
Andrew Gerrand
4f340f5051 godoc: canonicalize codewalk paths
R=rsc
CC=golang-dev
https://golang.org/cl/1729046
2010-06-30 17:56:51 +10:00
Russ Cox
829896168c ld: fix implementation of -u
R=r
CC=golang-dev
https://golang.org/cl/1678046
2010-06-29 18:59:48 -07:00
Ken Thompson
1246ad8390 code gen bug in len(nil) and cap(nil)
fixes #892

R=rsc
CC=golang-dev
https://golang.org/cl/1745042
2010-06-29 12:48:24 -07:00
Ken Thompson
2795282b50 compiler fatal error in switch.
fixes #867.

R=rsc
CC=golang-dev
https://golang.org/cl/1691045
2010-06-28 16:30:55 -07:00
Ken Thompson
e5d748a333 8g compiler missing call to splitclean().
fixes #887.

R=rsc
CC=golang-dev
https://golang.org/cl/1675050
2010-06-28 12:19:12 -07:00
Ken Thompson
33da9afc3e optimization of static initialization
R=rsc
CC=golang-dev
https://golang.org/cl/1677049
2010-06-27 17:37:01 -07:00
Russ Cox
6d8b8101ea gc: fix crash for nested complex division
R=ken2
CC=golang-dev
https://golang.org/cl/1720043
2010-06-23 10:55:50 -04:00
Russ Cox
6519a6ba5b ld: add -u flag to check safe bits; discard old -u, -x flags
R=r, r2
CC=golang-dev
https://golang.org/cl/1707043
2010-06-21 18:03:49 -07:00
Russ Cox
2fc0b4f01b gc: include struct field tags in type equality
R=ken2
CC=golang-dev
https://golang.org/cl/1667048
2010-06-21 13:06:39 -07:00
Roger Peppe
3ce29380d5 goinstall: process dependencies for package main
Currently to install a command, you have to manually
goinstall each of the remote packages that it depends on.
This patch lets goinstall P work where P is
contains files in package main.
It does not actually build the package, but
it installs all of its dependencies and prints a message
to that effect.

R=rsc
CC=golang-dev
https://golang.org/cl/1301043
2010-06-21 11:01:20 -07:00
Russ Cox
1b79cd2e71 undo changes accidentally included in 09c5add99d50
R=ken2
CC=golang-dev
https://golang.org/cl/1736042
2010-06-20 12:45:39 -07:00
Russ Cox
45bdf0367e reflect: add Kind, remove Int8Type, Int8Value, etc.
update other code to match.

R=r
CC=golang-dev
https://golang.org/cl/1680044
2010-06-20 12:16:25 -07:00
Russ Cox
9f002f6892 gc: delete debug print
R=ken2
CC=golang-dev
https://golang.org/cl/1732043
2010-06-20 12:15:10 -07:00
Russ Cox
a212d174ac gc: better error messages for interface failures, conversions
x.go:13: cannot use t (type T) as type Reader in assignment:
	T does not implement Reader (Read method requires pointer receiver)
x.go:19: cannot use q (type Q) as type Reader in assignment:
	Q does not implement Reader (missing Read method)
		have read()
		want Read()
x.go:22: cannot use z (type int) as type Reader in assignment:
	int does not implement Reader (missing Read method)

x.go:24: too many arguments to conversion to complex: complex(1, 3)

R=ken2
CC=golang-dev
https://golang.org/cl/1736041
2010-06-20 11:45:53 -07:00
Russ Cox
ceb868bf0a gc: fix build - subnode not addable in complexgen
R=ken2
CC=golang-dev
https://golang.org/cl/1677047
2010-06-20 11:21:43 -07:00
Nigel Tao
93ea2ae362 cmd/gotest: Delete temporary _testmain.go files.
R=rsc
TBR=rsc
CC=golang-dev
https://golang.org/cl/1675047
2010-06-16 13:37:07 +10:00
Russ Cox
d5a80d0ba4 gc: no more ...
various cleanup, deleting unused code

R=ken2
CC=golang-dev
https://golang.org/cl/1663041
2010-06-14 11:24:51 -07:00
Russ Cox
76da2780c3 gc: less aggressive name binding, for better line numbers in errors
Cleans up a few other corner cases too.

R=ken2
CC=golang-dev
https://golang.org/cl/1592045
2010-06-12 11:17:24 -07:00
Russ Cox
9d72aaabda gopack: add S flag to force marking a package as safe
R=r
CC=golang-dev
https://golang.org/cl/1597044
2010-06-12 10:47:42 -07:00
Russ Cox
089da369a3 8l: correct test for sp == top of stack in 8l -K code
R=ken2
CC=golang-dev
https://golang.org/cl/1627042
2010-06-11 16:17:47 -07:00
Russ Cox
ee0bca35a4 gopack: simplify go metadata code
There's only one Go object file per package now,
so there's no need to parse the metadata and merge
metadata from multiple files.  Just save the original
and use it as __.PKGDEF verbatim.

R=r
CC=golang-dev
https://golang.org/cl/1647042
2010-06-11 15:29:19 -07:00
Russ Cox
d20ad1c75a gc: change -u to require imports to be marked safe
R=ken2
CC=golang-dev
https://golang.org/cl/1597043
2010-06-11 15:28:43 -07:00
Ian Lance Taylor
fe43325b30 Pad Go symbol table out to page boundary when linking dynamically.
This avoids a crash when using cgo where glibc's malloc thinks
that it can use some of the memory following the symbol table.
This fails because the symbol table is mapped read-only, which
affects the whole page.

R=rsc
CC=golang-dev
https://golang.org/cl/1616042
2010-06-11 13:41:49 -07:00
Robert Griesemer
ace5269dfe go/scanner: report illegal escape sequences
R=golang-dev, r
CC=golang-dev
https://golang.org/cl/1636043
2010-06-09 15:19:22 -07:00
Russ Cox
a2a7d473f4 gc: more cleanup
* disallow surrogate pair runes.
 * diagnose impossible type assertions
 * eliminate another static buffer.
 * do not overflow lexbuf.
 * add -u flag to disable package unsafe.

R=ken2
CC=golang-dev
https://golang.org/cl/1619042
2010-06-09 11:00:55 -07:00
Russ Cox
565b5dc076 gc: new typechecking rules
* Code for assignment, conversions now mirrors spec.
* Changed some snprint -> smprint.
* Renamed runtime functions to separate
  interface conversions from type assertions:
  convT2I, assertI2T, etc.
* Correct checking of \U sequences.

Fixes #840.
Fixes #830.
Fixes #778.

R=ken2
CC=golang-dev
https://golang.org/cl/1303042
2010-06-08 18:50:02 -07:00
Robert Griesemer
4337c7c0bc gofmt: update test script so it can run to completion again
R=rsc
CC=golang-dev
https://golang.org/cl/1621041
2010-06-08 17:25:04 -07:00
Robert Griesemer
98b27814ae gc: better error message when ~ operator is found
Fixes #844.

R=ken2, rsc, ken3
CC=golang-dev
https://golang.org/cl/1593041
2010-06-07 18:27:26 -07:00
Robert Griesemer
0c222d6e49 gc: backslash newline is not a legal escape sequence in strings
Fixes #827.

R=ken2
CC=golang-dev, rsc
https://golang.org/cl/1592041
2010-06-07 18:10:48 -07:00
Daniel Theophanes
129c6c14d1 runtime: finish pchw -> tiny, added gettime for tiny
R=rsc
CC=golang-dev
https://golang.org/cl/1514041
2010-06-07 14:18:42 -07:00
Russ Cox
cd016d7558 gc: fix export of complex types
R=ken2
CC=golang-dev
https://golang.org/cl/1442042
2010-06-01 14:48:57 -07:00
Michael Hoisie
0c77ba96da goinstall: Use 'git pull' instead of 'git checkout' when updating a git repo.
R=rsc
CC=golang-dev
https://golang.org/cl/1395041
2010-06-01 14:27:45 -07:00
Ian Lance Taylor
1192c175fe Correct _cgo_free when C ABI does not pass first arg on stack.
It turns out that _cgo_malloc is used, via cmalloc in
runtime/cgocall.c, which is called by code generated by out.go
for the ·_C_CString function.  I can't find a call to
_cgo_free, but given _cgo_malloc we might as well keep
_cgo_free.  This patch fixes it so that it should work on
amd64.

R=rsc
CC=golang-dev
https://golang.org/cl/1399041
2010-05-30 22:22:47 -07:00
Russ Cox
bb84f4b5d2 changes &x -> x[0:] for array to slice conversion
R=gri
CC=golang-dev
https://golang.org/cl/1326042
2010-05-27 14:51:47 -07:00
Russ Cox
6a060200cc 8g: out of register bug
Fixes #806.

R=ken2
CC=golang-dev
https://golang.org/cl/1281042
2010-05-24 17:22:51 -07:00
Russ Cox
ea941f09bf gc: more accurate error description
R=ken2
CC=golang-dev
https://golang.org/cl/1284041
2010-05-24 17:07:51 -07:00
Russ Cox
8c2bc4419b gc: fix shift/reduce conflict in go.y export syntax
Fixes #771.

R=ken2
CC=golang-dev
https://golang.org/cl/1267042
2010-05-24 16:55:23 -07:00
Russ Cox
9fc9246bf3 gc: bug281 - bad overlap in stack copy
Fixes #807.

R=ken2
CC=golang-dev
https://golang.org/cl/1283041
2010-05-24 16:54:24 -07:00
Russ Cox
d14baee96e 6g: avoid unnecessary conversion in shift bounds check
R=ken2
CC=golang-dev
https://golang.org/cl/1278042
2010-05-24 15:30:53 -07:00
Russ Cox
2e9b67afa6 gc: bug277 - new conversion syntax
R=ken2
CC=golang-dev
https://golang.org/cl/1220046
2010-05-24 15:25:30 -07:00
Russ Cox
43c0a46ac6 gc: bug280
Fixes #808.

R=ken2
CC=golang-dev
https://golang.org/cl/1273042
2010-05-24 15:25:09 -07:00
Russ Cox
5e253645d2 gc: bug278
Fixes #804.

R=ken2
CC=golang-dev
https://golang.org/cl/1224045
2010-05-24 14:22:54 -07:00