summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2009-07-30fix build on amd64Russ Cox4-1/+10
R=ken OCL=32521 CL=32521
2009-07-29fixed golden.out, which is what 32496 should have done.Russ Cox2-2/+9
roll back 32496 TBR=austin OCL=32499 CL=32501
2009-07-29fix buildRuss Cox1-8/+1
TBR=austin OCL=32496 CL=32496
2009-07-29handle unsupported types safely.Rob Pike6-75/+140
R=rsc DELTA=154 (71 added, 6 deleted, 77 changed) OCL=32483 CL=32492
2009-07-29parser:Robert Griesemer5-176/+146
- Changed filter function for parser.ParsePackage to take an *os.Dir instead of a filename for more powerful filters - Removed TODO in ast.PackageInterface: Now collect package comments from all package files - Cleanups in godoc: Use the new ParsePackage and PackageInterface functions; as a result computing package information is much simpler now. R=rsc DELTA=285 (80 added, 110 deleted, 95 changed) OCL=32473 CL=32486
2009-07-29break tabwriter columns when starting a new block of indented statementsRobert Griesemer3-1/+16
R=r DELTA=16 (15 added, 0 deleted, 1 changed) OCL=32475 CL=32481
2009-07-29bug136 unfixedRuss Cox2-4/+11
R=austin DELTA=35 (21 added, 14 deleted, 0 changed) OCL=32469 CL=32474
2009-07-29fix typoRob Pike1-1/+1
R=rsc OCL=32472 CL=32472
2009-07-29another test error tweakRuss Cox1-1/+3
5 known bugs; 0 unexpected bugs; test output differs R=r DELTA=3 (2 added, 0 deleted, 1 changed) OCL=32468 CL=32470
2009-07-29clean up EOFRob Pike2-5/+4
R=rsc DELTA=5 (0 added, 1 deleted, 4 changed) OCL=32465 CL=32467
2009-07-29tweak final line of test output:Russ Cox2-15/+32
4 known bugs; 0 unexpected bugs which should be less scary to people unfamiliar with the tests. R=r DELTA=44 (29 added, 12 deleted, 3 changed) OCL=32460 CL=32464
2009-07-29handle some error conditions involving bad data.Rob Pike3-8/+31
R=rsc DELTA=32 (24 added, 1 deleted, 7 changed) OCL=32461 CL=32463
2009-07-29break and continue fixesRuss Cox7-31/+85
labeled break/continue was using first loop with any label, not first loop with the right label. R=ken OCL=32453 CL=32458
2009-07-29statistics HTML page for rpcRob Pike3-5/+121
R=rsc DELTA=121 (115 added, 0 deleted, 6 changed) OCL=32427 CL=32429
2009-07-29introduce typecheck pass before walkexpr.Russ Cox6-109/+394
not complete but compiler still works. R=ken OCL=32424 CL=32426
2009-07-29convert walkexpr to take Node**; drop indirRuss Cox7-215/+225
R=ken OCL=32421 CL=32421
2009-07-29Flatten the Frame tree. Now each function call produces aAustin Clements8-206/+218
single frame and non-overlapping variables reuse frame slots. As a result, entering and exiting blocks no longer requires code execution, which means jumps across block boundaries should be doable now. Frame slot initialization happens at definition time now, instead of at frame creation time. As an added bonus, Scope's are now exclusively compile-time objects and we no longer need to specially track the function activation frame for access to out vars. R=rsc APPROVED=rsc DELTA=313 (102 added, 90 deleted, 121 changed) OCL=32416 CL=32420
2009-07-29expression printer; %#NRuss Cox4-0/+340
R=ken OCL=32419 CL=32419
2009-07-29quietgcc: do not use -m64 on 32-bit machinesRuss Cox1-1/+10
R=r DELTA=9 (8 added, 0 deleted, 1 changed) OCL=32413 CL=32418
2009-07-28make every func literal expression allocate,Russ Cox4-129/+138
so that == on func means that the functions originated in the same execution of a func literal or definition. before, there was an inconsistency: func() {x++} != func() {x++} but func() {} == func() {} this CL makes the second case != too, just like make(map[int]int) != make(map[int]int) R=r DELTA=202 (71 added, 62 deleted, 69 changed) OCL=32393 CL=32398
2009-07-28Add a unique list ID to list elements, and verify it as necessary.David Symonds1-4/+18
This makes the list closed under its provided operations. R=rsc,gri APPROVED=rsc DELTA=18 (14 added, 0 deleted, 4 changed) OCL=32388 CL=32395
2009-07-28missed changes to Makefiles for container/ringRobert Griesemer2-0/+3
R=rsc DELTA=3 (3 added, 0 deleted, 0 changed) OCL=32389 CL=32392
2009-07-28change the encoding of uints to simplify overflow checking and to make themRob Pike7-98/+136
easier and faster to read. they are now either a one-byte value or a n-byte value preceded by a byte holding -n. R=rsc DELTA=150 (45 added, 7 deleted, 98 changed) OCL=32381 CL=32387
2009-07-28fix error that gcc thinks is a warningRuss Cox2-2/+2
R=ken OCL=32264 CL=32386
2009-07-28bug177: anonymous struct fields in reflectRuss Cox4-18/+42
(reported by iant) R=r DELTA=50 (32 added, 12 deleted, 6 changed) OCL=32263 CL=32385
2009-07-28Implement comparison operators.Austin Clements1-21/+302
R=rsc APPROVED=rsc DELTA=304 (281 added, 0 deleted, 23 changed) OCL=32361 CL=32382
2009-07-28Intersperse comments nicely when printing an AST.Robert Griesemer12-190/+359
gofmt formatted source code looks pretty good already; with a bit more fine-tuning it should be great. printer.go: - Implemented comment intersperse algorithm. The approach is a result of many trial-and-error experiments but at this point reasonably simple and open to arbitrary fine-tuning. parser.go: - Simplified handling of lead and line comments (formerly called leading and trailing comments). - Use a comments list instead of an array (I may change this back - this is not obviously better and uses more space). doc.go: - Remove comments from AST nodes that have been 'consumed' in the documentation to avoid duplicate printing of them. Allows for better control of what is printed w/o use of printing control flags (which are hard to use and not fine-grained enough). Corresponding adjustments to various clients of these files. R=rsc DELTA=478 (275 added, 108 deleted, 95 changed) OCL=32185 CL=32380
2009-07-28Fix segfault on unnamed function arguments. Make continueAustin Clements1-4/+9
jump to the post statement instead of the condition check. R=rsc APPROVED=rsc DELTA=10 (6 added, 1 deleted, 3 changed) OCL=32359 CL=32379
2009-07-28Fixed typos in comments.Robert Griesemer1-4/+4
TBR=rsc OCL=32330 CL=32330
2009-07-28Ring ADT.Robert Griesemer3-0/+495
- Provides analogous functionality to a doubly-linked list implementation. - Completely symmetric set of operations. - Operations on the ADT do not lead to results that are outside the domain of the ADT (closed interface). - Alternative to container/list. R=rsc DELTA=489 (489 added, 0 deleted, 0 changed) OCL=32284 CL=32323
2009-07-28floating-point limits and equationsRuss Cox1-5/+11
R=r DELTA=13 (8 added, 2 deleted, 3 changed) OCL=32291 CL=32322
2009-07-28fmt boundary bugs.Russ Cox1-4/+13
pow10 was giving up too easily. R=r DELTA=4 (0 added, 3 deleted, 1 changed) OCL=32310 CL=32321
2009-07-28Implement if, for (modulo ranges), break, continue, increment,Austin Clements3-31/+322
and decrement. blockCompilers now form a tree the mimics the nesting of scopes and provide convenient ways to enter and exit scopes. blockCompilers also track the break and continue PC for the current block. The statement testing interface now works in lists of statements, which simplifies a bunch of things. R=rsc APPROVED=rsc DELTA=401 (335 added, 44 deleted, 22 changed) OCL=32308 CL=32317
2009-07-28- clean up code creating keys for type mapsRob Pike5-125/+362
- derive int, uint, float, uintptr decoders based on their size - add overflow checks in decode R=rsc DELTA=407 (281 added, 44 deleted, 82 changed) OCL=32286 CL=32290
2009-07-28constants for integer limitsRob Pike1-0/+16
R=rsc DELTA=16 (16 added, 0 deleted, 0 changed) OCL=32288 CL=32288
2009-07-28constants for floating point limitsRob Pike1-0/+5
R=rsc DELTA=5 (5 added, 0 deleted, 0 changed) OCL=32283 CL=32287
2009-07-28Support use of $GOBINDIR to override $HOME/binPhil Pennock26-38/+42
R=r,gri,rsc APPROVED=rsc DELTA=53 (12 added, 6 deleted, 35 changed) OCL=31822 CL=32282
2009-07-28Fix bug where typeArrayMap was using the address of theAustin Clements1-1/+1
pointer to the Type instead of the address of the Type. R=rsc APPROVED=rsc DELTA=1 (0 added, 0 deleted, 1 changed) OCL=32265 CL=32279
2009-07-27constant keys for array initializersRuss Cox3-1/+18
R=ken OCL=32261 CL=32261
2009-07-27Implement multi-valued functions, multi-valued return, andAustin Clements5-164/+425
unpacking for assignments, call arguments, and returns. This change revamps the whole assignment compilation system to be multi-valued, using the new MultiType type and multiV value. Function calls, returns, and assignments now share a lot of code and produce very consistent error messages. R=rsc APPROVED=rsc DELTA=510 (335 added, 74 deleted, 101 changed) OCL=32248 CL=32258
2009-07-27move bug148, already fixed, to fixedbugsRuss Cox2-7/+7
R=ken OCL=32257 CL=32257
2009-07-27document rpc.Rob Pike3-34/+158
R=rsc DELTA=160 (124 added, 0 deleted, 36 changed) OCL=32233 CL=32256
2009-07-27bug170; fix test for bug175Russ Cox3-10/+5
R=ken OCL=32255 CL=32255
2009-07-27multiple return in := bugRuss Cox4-0/+33
R=ken OCL=32253 CL=32253
2009-07-27print(1<<x)Russ Cox3-4/+17
R=ken OCL=32252 CL=32252
2009-07-27avoid register computing len(x), cap(x)Russ Cox6-29/+111
for slice or string x. R=ken OCL=32249 CL=32249
2009-07-27Fix bug where nothing could ever be added to a code buffer.Austin Clements1-2/+2
R=rsc APPROVED=rsc DELTA=2 (0 added, 0 deleted, 2 changed) OCL=32245 CL=32247
2009-07-27named string type bugsRuss Cox2-5/+34
R=ken OCL=32244 CL=32244
2009-07-27catchRuss Cox2-3/+21
a := true; a |= a; in the front end. R=ken OCL=32240 CL=32243
2009-07-27do not insert implicit "return;" in empty function bodyRuss Cox5-3/+15
R=ken OCL=32239 CL=32239