remove now-unused ts field from ann
This commit is contained in:
parent
e16b097599
commit
bb594a03a1
4 changed files with 6 additions and 19 deletions
|
@ -23,8 +23,7 @@ type ty_param = ident;
|
|||
// Annotations added during successive passes.
|
||||
type ann = rec(uint id,
|
||||
middle::ty::t ty,
|
||||
option::t[vec[middle::ty::t]] tps,
|
||||
option::t[@ts_ann] ts);
|
||||
option::t[vec[middle::ty::t]] tps);
|
||||
|
||||
tag def {
|
||||
def_fn(def_id);
|
||||
|
|
|
@ -147,11 +147,10 @@ fn new_parser(session::session sess,
|
|||
fn get_chpos() -> uint {ret rdr.get_chpos();}
|
||||
|
||||
fn get_ann() -> ast::ann {
|
||||
// TODO: Remove ty, tps, and ts. ty and tps should be unused
|
||||
// TODO: Remove ty and tps, which should be unused
|
||||
// by now.
|
||||
auto rv = rec(id=next_ann_var, ty=0u,
|
||||
tps=none[vec[middle::ty::t]],
|
||||
ts=none[@middle::tstate::ann::ts_ann]);
|
||||
tps=none[vec[middle::ty::t]]);
|
||||
next_ann_var += 1u;
|
||||
ret rv;
|
||||
}
|
||||
|
|
|
@ -1498,7 +1498,7 @@ fn ann_to_monotype(ctxt cx, &node_type_table ntt, ast::ann a) -> t {
|
|||
// Turns a type and optional type parameters into an annotation, using
|
||||
// defaults for other fields.
|
||||
fn mk_ann_type(uint node_id, t typ, option::t[vec[t]] tps) -> ast::ann {
|
||||
ret rec(id=node_id, ty=typ, tps=tps, ts=none[@ts_ann]);
|
||||
ret rec(id=node_id, ty=typ, tps=tps);
|
||||
}
|
||||
|
||||
// Turns a type into an annotation, using defaults for other fields.
|
||||
|
|
|
@ -178,8 +178,8 @@ fn item_to_str(&@ast::item i) -> str {
|
|||
auto out_ = mkstate(s.get_writer(), 80u);
|
||||
auto out = @rec(s=out_,
|
||||
comments=none[vec[front::lexer::cmnt]],
|
||||
mutable cur_cmnt=0u);
|
||||
|
||||
mutable cur_cmnt=0u,
|
||||
mode=mo_untyped);
|
||||
print_item(out, i);
|
||||
ret s.get_str();
|
||||
}
|
||||
|
@ -196,17 +196,6 @@ fn log_item_err(&@ast::item i) -> () {
|
|||
log_err(item_to_str(i));
|
||||
}
|
||||
|
||||
fn log_ann(&ast::ann a) -> () {
|
||||
alt (a) {
|
||||
case (ast::ann_none(_)) {
|
||||
log("ann_none");
|
||||
}
|
||||
case (ast::ann_type(_,_,_,_)) {
|
||||
log("ann_type");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
fn fun_to_str(&ast::_fn f, str name, vec[ast::ty_param] params) -> str {
|
||||
let str_writer s = string_writer();
|
||||
auto out_ = mkstate(s.get_writer(), 80u);
|
||||
|
|
Loading…
Reference in a new issue