1
0
mirror of https://github.com/golang/go synced 2024-11-14 20:50:30 -07:00
Commit Graph

4 Commits

Author SHA1 Message Date
Austin Clements
da4a22993e Fix declared and not used errors and unused import errors in
the interpreter and update code to use ast.BasicDecl and
multi-type switch.  There are still a lot of "switch _ :=
x.(type)" that should make use of the new type switch syntax,
but those will be a different CL.

R=rsc
APPROVED=rsc
DELTA=58  (16 added, 23 deleted, 19 changed)
OCL=34853
CL=34963
2009-09-24 08:25:14 -07:00
Austin Clements
7c9b9af76e Convert interpreter to whole-package compilation.
R=rsc
APPROVED=rsc
DELTA=334  (110 added, 211 deleted, 13 changed)
OCL=33135
CL=33137
2009-08-12 17:24:05 -07:00
Austin Clements
79fac7ca86 Implement array types and index expressions.
Some cleanup.  Elem() on PtrType is now just Elem and matches
with ArrayType.  Generators now switch over the result type
instead of the operand type.  Delete unused diag function.

R=rsc
APPROVED=rsc
DELTA=281  (219 added, 18 deleted, 44 changed)
OCL=31876
CL=31891
2009-07-20 17:41:40 -07:00
Austin Clements
9211a7d413 Beginnings of a Go interpreter. This implements basic and
pointer types, supports literals, identifiers, type-checking
most unary and binary operators, "compiling" a few unary and
binary operators, and assignment and declaration statements.

R=rsc
APPROVED=rsc
DELTA=1751  (1751 added, 0 deleted, 0 changed)
OCL=31309
CL=31691
2009-07-15 11:59:13 -07:00