aboutsummaryrefslogtreecommitdiff
path: root/src/comp/front/ast.rs
diff options
context:
space:
mode:
authorGraydon Hoare <[email protected]>2010-12-14 17:42:12 -0800
committerGraydon Hoare <[email protected]>2010-12-14 17:42:12 -0800
commitb1e0c60d6dee3832358be1b4b8303fe6ade6be4c (patch)
tree0a28b1b0489af217b9ad5e33eb1fc3025658972a /src/comp/front/ast.rs
parentTeach resolve about obj items. (diff)
downloadrust-b1e0c60d6dee3832358be1b4b8303fe6ade6be4c.tar.xz
rust-b1e0c60d6dee3832358be1b4b8303fe6ade6be4c.zip
Add ty_obj to ast and parser.
Diffstat (limited to 'src/comp/front/ast.rs')
-rw-r--r--src/comp/front/ast.rs3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/comp/front/ast.rs b/src/comp/front/ast.rs
index 3b6ebd35..88b7fc78 100644
--- a/src/comp/front/ast.rs
+++ b/src/comp/front/ast.rs
@@ -171,6 +171,8 @@ tag lit_ {
type ty_field = rec(ident ident, @ty ty);
type ty_arg = rec(mode mode, @ty ty);
+// TODO: effect
+type ty_method = rec(ident ident, vec[ty_arg] inputs, @ty output);
type ty = spanned[ty_];
tag ty_ {
ty_nil;
@@ -185,6 +187,7 @@ tag ty_ {
ty_tup(vec[@ty]);
ty_rec(vec[ty_field]);
ty_fn(vec[ty_arg], @ty); // TODO: effect
+ ty_obj(vec[ty_method]);
ty_path(path, option.t[def]);
ty_mutable(@ty);
}