summaryrefslogtreecommitdiff
path: root/usr/austin/eval/decls.go
diff options
context:
space:
mode:
authorAustin Clements <aclements@csail.mit.edu>2009-08-05 11:49:51 -0700
committerAustin Clements <aclements@csail.mit.edu>2009-08-05 11:49:51 -0700
commitc8b49a4532508beea09fe32b8ff2ce8670e88652 (patch)
tree52b8f1b2dd990c619a8b473c8702d3f0a2c6d26c /usr/austin/eval/decls.go
parent3bd3459d14bc33de204f0558688f2e908c35a2f8 (diff)
downloadgolang-c8b49a4532508beea09fe32b8ff2ce8670e88652.tar.gz
Implement struct types, selector expressions, and type
declarations. R=rsc APPROVED=rsc DELTA=587 (519 added, 21 deleted, 47 changed) OCL=32754 CL=32788
Diffstat (limited to 'usr/austin/eval/decls.go')
-rw-r--r--usr/austin/eval/decls.go9
1 files changed, 9 insertions, 0 deletions
diff --git a/usr/austin/eval/decls.go b/usr/austin/eval/decls.go
index 3b1ed70ae..c34baed87 100644
--- a/usr/austin/eval/decls.go
+++ b/usr/austin/eval/decls.go
@@ -22,6 +22,8 @@ type Type interface {
// same named type. If conv if true, this is conversion
// compatibility, where two named types are conversion
// compatible if their definitions are conversion compatible.
+ //
+ // TODO(austin) Deal with recursive types
compat(o Type, conv bool) bool;
// lit returns this type's literal. If this is a named type,
// this is the unnamed underlying type. Otherwise, this is an
@@ -113,6 +115,13 @@ type ArrayValue interface {
Elem(i int64) Value;
}
+type StructValue interface {
+ Value;
+ // TODO(austin) This is another useless Get()
+ Get() StructValue;
+ Field(i int) Value;
+}
+
type PtrValue interface {
Value;
Get() Value;