summaryrefslogtreecommitdiff
path: root/src/cmd/gc/walk.c
AgeCommit message (Collapse)AuthorFilesLines
2009-07-076g, 8g: generate data structures for new reflect interface (CL 31107)Russ Cox1-16/+5
R=ken OCL=31122 CL=31278
2009-07-06shift typechecking bugsRuss Cox1-1/+1
x << "a" 1 << int(2) R=ken OCL=31244 CL=31244
2009-07-06statements after panicln are unreachable, just like after panic.Russ Cox1-3/+2
missing break after error. dot symbol bug fix: leave sym alone (was incorrect for inserted cross-package dots). R=ken OCL=31234 CL=31236
2009-07-06allow conversion to interface typeRuss Cox1-1/+8
when implicit assignment would have been okay. R=ken OCL=31225 CL=31227
2009-07-04another seg faultKen Thompson1-1/+2
R=r OCL=31156 CL=31156
2009-07-03maps have == so maps are okay as map keys.Russ Cox1-8/+6
alignment issue is fixed. R=ken OCL=31124 CL=31144
2009-06-25better error; clean up lineno in a few placesRuss Cox1-11/+14
wreck.mtv=; cat x.go package main var x = string.Split() wreck.mtv=; 6g x.go x.go:2: type string used as expression x.go:2: undefined DOT Split on string x.go:3: illegal types for operand: AS undefined wreck.mtv=; BUG=1938751 R=ken OCL=30766 CL=30766
2009-06-256g: update for spec change CL 30586Russ Cox1-9/+5
R=ken OCL=30593 CL=30756
2009-06-23fix a 6g crash after type errors.Russ Cox1-5/+13
do not bother warning about marks left on stack after syntax errors. leave OCONV nodes in tree to avoid type errors arising from multiple walks. R=ken OCL=30639 CL=30662
2009-06-19implement new spec language regarding conversionsRuss Cox1-15/+26
R=ken OCL=30519 CL=30534
2009-06-06gc: grammar cleanup:Russ Cox1-43/+57
* no longer distinguishes const, var, type, package names. * all the predefined names are not tokens anymore. R=ken OCL=29326 CL=29985
2009-06-03zero struct in T{}Russ Cox1-1/+1
R=ken OCL=29849 CL=29849
2009-06-02minor cleanup, 64-bit /= and %= on 32-bitRuss Cox1-4/+16
R=ken OCL=29806 CL=29808
2009-05-31prevent multiple similar errorsKen Thompson1-14/+35
in complex literals. side effect is fix of error in initializerr.go R=r OCL=29667 CL=29667
2009-05-30bug157Russ Cox1-62/+59
R=ken OCL=29651 CL=29653
2009-05-28print uint64 as uint64.Russ Cox1-1/+4
R=ken OCL=29568 CL=29570
2009-05-27bug 153Ken Thompson1-1/+6
R=r OCL=29479 CL=29479
2009-05-27string([]int) conversionKen Thompson1-1/+19
R=r OCL=29466 CL=29466
2009-05-268g: 64-bit arithmetic and assorted bug fixes;Russ Cox1-0/+29
can run 64-bit sieve and powser. interfaces are limping along. next hurdle is floating point. R=ken OCL=29418 CL=29423
2009-05-26bug 152Ken Thompson1-11/+20
R=r OCL=29419 CL=29419
2009-05-26bug 151Ken Thompson1-6/+15
R=r OCL=29409 CL=29409
2009-05-26bug 150Ken Thompson1-38/+45
R=r OCL=29405 CL=29405
2009-05-231. check for dups in complex literalsKen Thompson1-46/+156
structtype{a:1, a:2} maptypetype{"xx":1, "xx":2} arraytypetype{5:1, 5:2} 2. bug in registerization concerning alias of a struct and one of its elements 3. code optimization of struct.field (which exposed bug in 2) R=r OCL=29315 CL=29315
2009-05-21enforce channel directionRuss Cox1-11/+40
R=ken OCL=29209 CL=29216
2009-05-21some array init bugsKen Thompson1-3/+6
renamed 6g/(gen|align|obj).c R=r OCL=29205 CL=29205
2009-05-21stricter rules for assignment.Russ Cox1-1/+46
when assigning a multifield object (structs or arrays of structs) they must not contain any fields that could not be assigned individually. R=ken OCL=29192 CL=29194
2009-05-21added key:val extension toKen Thompson1-28/+84
structure and array literals R=r OCL=29190 CL=29190
2009-05-20stricter interface conversion rule: i.(T)Russ Cox1-1/+6
must have non-nil i. R=ken OCL=29136 CL=29136
2009-05-20ifaceop was being called with integersRuss Cox1-14/+29
that came from two different enums. spilt into ifacecvt and ifaceop depending on which enum the argument is. R=ken OCL=29122 CL=29122
2009-05-20change representation of interface values.Russ Cox1-16/+101
this is not a user-visible change. before, all interface values were struct Itype { Sigt *type; Sigi *inter; void *method[n]; } struct Iface { void *addr; Itype *itype; } the itype is basically a vtable, but it's unnecessary if the static type is interface{ }. for interface values with static type empty, the new representation is struct Eface { void *addr; Sigt *type; } this complicates the code somewhat, but it reduces the number of Itypes that have to be computed and cached, it opens up opportunities to avoid function calls in a few common cases, and it will make it possible to lay out interface{} values at compile time, which i think i'll need for the new reflection. R=ken OCL=28701 CL=29121
2009-05-20fix implicit star for range on *map, *[].Russ Cox1-7/+11
do not update lineno from ONAME nodes, because they have declaration lineno not use. show actual name in top-level statement error. before runtime.a:7: x.go:5: walkstate: NAME not a top level statement after x.go:14: walkstate: runtime.Goexit not a top level statement R=ken OCL=29113 CL=29116
2009-05-18static initialization of slicesKen Thompson1-0/+4
R=r OCL=29016 CL=29016
2009-05-17static initialization with DATA statementsKen Thompson1-29/+30
structs and arrays are done slices and maps are yet to do R=r OCL=28977 CL=28977
2009-05-14fix spelling error in messageRob Pike1-1/+1
R=ken OCL=28814 CL=28814
2009-05-086g:Russ Cox1-9/+2
new type equality restrictions better handling of renamed packages "sys" is no longer available to programs R=ken OCL=28553 CL=28578
2009-05-08eqtype(t1, t2, 0) => eqtype(t1, t2)Russ Cox1-16/+16
R=ken OCL=28559 CL=28562
2009-05-07if a struct s contains an anonymous interface valueRuss Cox1-2/+5
with method m, s.m() is ok and m now shows up in s's method set for interface runtime. see http://cl/28419-p2 for new test interface10.go. R=ken OCL=28420 CL=28423
2009-05-076g: error messagesRuss Cox1-5/+61
replace "shape error across CALL" with more information. x.go:7: not enough arguments to CALL a int, b int int x.go:10: assignment count mismatch: 3 = 2 x.go:12: too many arguments to RETURN [no arguments expected] int, int, int also leave type alone after conversion failure, for later errors: bug049.go:6: cannot convert nil constant to string bug049.go:6: illegal types for operand: EQ string nil # this used to be blank R=ken OCL=28405 CL=28407
2009-05-066g: new interface rules (code got simpler!)Russ Cox1-8/+8
R=ken OCL=28374 CL=28378
2009-04-30bug146: array/slice conversion before I left missed conversionsRuss Cox1-27/+10
R=ken OCL=28120 CL=28124
2009-04-24recognize a defined constantKen Thompson1-2/+19
as a new name in a later declaration (bug 144) R=r OCL=27850 CL=27850
2009-04-212 minor bugs.Ken Thompson1-2/+2
lv context for some [] operations calling implicit(*map) before walk. R=r OCL=27706 CL=27706
2009-04-21supply default indirection toKen Thompson1-0/+2
map indexing - bug 143 R=r OCL=27695 CL=27695
2009-04-18mixed old/new declarationKen Thompson1-10/+89
exact spec: a) must be a multi-assignment w := b) a proper subset of the lhs can be declared in same block with the same type with no "redeclaration" error R=r OCL=27610 CL=27610
2009-04-16make string(array) take []byte only (and thus *[10]byte but not [10]byte)Russ Cox1-4/+6
R=ken OCL=27581 CL=27585
2009-04-15panicln: emit just one newlineRuss Cox1-2/+6
R=ken OCL=27537 CL=27545
2009-04-15compiler implementation of array slice changeRuss Cox1-7/+13
R=ken OCL=27533 CL=27533
2009-04-13fix stringrange testRuss Cox1-20/+28
R=ken OCL=27353 CL=27353
2009-04-10range over stringsKen Thompson1-2/+75
R=r OCL=27332 CL=27332
2009-04-08yet another attempt at auto-linkingRuss Cox1-2/+2
store only the original import path string (+ .a) if 6g resolves it to an archive file. let 6l re-resolve the .a at link time. this lets libraries build against an archive in the current directory but get used against an installed archive. R=r OCL=27244 CL=27244