From cf2def46c120d8d6ef8a98571a39bef478c8c2a9 Mon Sep 17 00:00:00 2001 From: Eric Holk Date: Mon, 15 Aug 2011 16:54:02 -0700 Subject: Removed trans_comm.rs from the compiler. Updating aio/sio to work with the new chan and port system, started on a networking module for the standard library. --- src/comp/syntax/parse/parser.rs | 39 --------------------------------------- 1 file changed, 39 deletions(-) (limited to 'src/comp/syntax/parse') diff --git a/src/comp/syntax/parse/parser.rs b/src/comp/syntax/parse/parser.rs index 93cdf617a63..e807fda20f9 100644 --- a/src/comp/syntax/parse/parser.rs +++ b/src/comp/syntax/parse/parser.rs @@ -577,16 +577,6 @@ fn parse_ty(p: &parser, colons_before_params: bool) -> @ast::ty { alt t { ast::ty_fn(_, _, out, _, _) { hi = out.span.hi; } } } else if (eat_word(p, "obj")) { t = parse_ty_obj(p, hi); - } else if (eat_word(p, "port")) { - expect(p, token::LBRACKET); - t = ast::ty_port(parse_ty(p, false)); - hi = p.get_hi_pos(); - expect(p, token::RBRACKET); - } else if (eat_word(p, "chan")) { - expect(p, token::LBRACKET); - t = ast::ty_chan(parse_ty(p, false)); - hi = p.get_hi_pos(); - expect(p, token::RBRACKET); } else if (eat_word(p, "mutable")) { p.warn("ignoring deprecated 'mutable' type constructor"); let typ = parse_ty(p, false); @@ -990,30 +980,11 @@ fn parse_bottom_expr(p: &parser) -> @ast::expr { } } else if (eat_word(p, "be")) { let e = parse_expr(p); - - // FIXME: Is this the right place for this check? if /*check*/ast::is_call_expr(e) { hi = e.span.hi; ex = ast::expr_be(e); } else { p.fatal("Non-call expression in tail call"); } - } else if (eat_word(p, "port")) { - let ty = @spanned(lo, hi, ast::ty_infer); - if token::LBRACKET == p.peek() { - expect(p, token::LBRACKET); - ty = parse_ty(p, false); - expect(p, token::RBRACKET); - } - expect(p, token::LPAREN); - expect(p, token::RPAREN); - hi = p.get_hi_pos(); - ex = ast::expr_port(ty); - } else if (eat_word(p, "chan")) { - expect(p, token::LPAREN); - let e = parse_expr(p); - hi = e.span.hi; - expect(p, token::RPAREN); - ex = ast::expr_chan(e); } else if (eat_word(p, "copy")) { let e = parse_expr(p); ex = ast::expr_copy(e); @@ -1271,16 +1242,6 @@ fn parse_assign_expr(p: &parser) -> @ast::expr { let rhs = parse_expr(p); ret mk_expr(p, lo, rhs.span.hi, ast::expr_move(lhs, rhs)); } - token::SEND. { - p.bump(); - let rhs = parse_expr(p); - ret mk_expr(p, lo, rhs.span.hi, ast::expr_send(lhs, rhs)); - } - token::RECV. { - p.bump(); - let rhs = parse_expr(p); - ret mk_expr(p, lo, rhs.span.hi, ast::expr_recv(lhs, rhs)); - } token::DARROW. { p.bump(); let rhs = parse_expr(p); -- cgit 1.4.1-3-g733a5