diff options
author | Austin Clements <aclements@csail.mit.edu> | 2009-07-30 14:39:27 -0700 |
---|---|---|
committer | Austin Clements <aclements@csail.mit.edu> | 2009-07-30 14:39:27 -0700 |
commit | 96e1969da9cb424435bd31f2c912b15ce6e89fa1 (patch) | |
tree | 2fe900def247d1d92afe550b73763aeacf10a07f /usr/austin/eval/decls.go | |
parent | 6a40b7b0896e5de398a9e1af52d244621a1a56e4 (diff) | |
download | golang-96e1969da9cb424435bd31f2c912b15ce6e89fa1.tar.gz |
Implement labels, goto, labeled break, and labeled continue.
Return checking is now done as a general flow check at the end
of function compilation, since break and goto complicated the
way I was doing return checking before. Goto-over-declaration
checking is also done as a final flow check.
Temporary variables used for effect extraction are now
actually temporary. Otherwise "op=", "++", and "--" appear as
declarations that cannot be jumped over.
R=rsc
APPROVED=rsc
DELTA=421 (344 added, 38 deleted, 39 changed)
OCL=32527
CL=32535
Diffstat (limited to 'usr/austin/eval/decls.go')
-rw-r--r-- | usr/austin/eval/decls.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/usr/austin/eval/decls.go b/usr/austin/eval/decls.go index 2f71f11f3..439b8b216 100644 --- a/usr/austin/eval/decls.go +++ b/usr/austin/eval/decls.go @@ -178,7 +178,7 @@ func (b *block) enterChild() *block func (b *block) exit() func (b *block) ChildScope() *Scope func (b *block) DefineVar(name string, t Type) *Variable -func (b *block) DefineTemp(t Type) *Variable +func (b *block) DefineSlot(t Type) *Variable func (b *block) DefineConst(name string, t Type, v Value) *Constant func (b *block) DefineType(name string, t Type) Type func (b *block) Lookup(name string) (level int, def Def) |