tests to use new reflect interface.
also make tests a real gotest.
depends on CL 31107
R=r
DELTA=582 (56 added, 194 deleted, 332 changed)
OCL=31108
CL=31279
s.output.Data() was being retrieved before the synchronization
point, which meant that it could be retrieved before the
goroutine wrote it. Using gccgo this caused random errors.
R=gri
DELTA=2 (1 added, 0 deleted, 1 changed)
OCL=31046
CL=31267
Natural, Integer, and Rational numbers
- added Value() methods to access small Natural and Integers
as uint64 or int64 respectively, and to get the components
of Rational numbers
- fixed a bug with Integer creation
- removed some _'s from names
- added more comments in places
- added test cases
R=rsc
DELTA=184 (127 added, 11 deleted, 46 changed)
OCL=31210
CL=31265
* use structs instead of interfaces
* compiler lays out data structures ahead of time,
so no more parsing of strings.
* unified reflect data structures with interface
runtime data structures.
* richer data structures should enable reflection
on chans and maps, but not implemented here.
R=r,iant
DELTA=1179 (1179 added, 0 deleted, 0 changed)
OCL=31107
CL=31213
- display: show '...' if a struct/interface has fields/methods removed; show
struct/interface w/o {}'s if all fields/methods were removed; and show the
{}'s if the struct/interface was empty to begin with
R=rsc
DELTA=41 (36 added, 0 deleted, 5 changed)
OCL=31201
CL=31204
- use FilterExports instead of the various predicates in printer.go and doc.go
which simplifies a lot of code and makes it easier to deal with complex cases
R=rsc
DELTA=445 (197 added, 190 deleted, 58 changed)
OCL=31110
CL=31196
fix a bug in delta encoding: only update the delta-base if something is marshaled.
R=rsc
DELTA=154 (94 added, 56 deleted, 4 changed)
OCL=31069
CL=31071
if there is an error, we will write one more value into the struct but in return
we do fewer tests in the decode.
R=rsc
DELTA=56 (0 added, 42 deleted, 14 changed)
OCL=31041
CL=31044
now that cgo2c can handle it,
merge x.c and x_go.cgo into
a single x.cgo, for x=float,malloc,sema.
R=r
DELTA=1950 (954 added, 996 deleted, 0 changed)
OCL=30951
CL=30964
align the output args separately from the input args,
change cgo2c to insert the necessary padding
when the two arg lists are concatenated in the c
translation.
for example, there is a runtime
func indexstring(s string, i int32) (b byte)
right now in 6g those arguments are aligned in one
struct with s at offset 0, i at 16, and b at 20.
soon the b byte will be in its own struct and structs
are 8 aligned, so it will be b at 24.
right now cgo2c generates:
void indexstring(string s, int32 i, byte b)
this CL makes it generate, in --6g mode:
void indexstring(string s, int32 i, uint32, byte b)
this is valid 6c input, although not valid gcc input.
(the code is being generated for 6c only anyway.)
also, allow C code to be mixed in among the Go funcs.
every instance of the token `func' is expected to start
a new go func.
R=iant
DELTA=145 (118 added, 0 deleted, 27 changed)
OCL=30949
CL=30963