Skip to content

Commit 93f6fd9

Browse files
committed
---
yaml --- r: 36156 b: refs/heads/try2 c: 62f98c8 h: refs/heads/master v: v3
1 parent 0b00c1a commit 93f6fd9

File tree

23 files changed

+155
-243
lines changed

23 files changed

+155
-243
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ refs/heads/snap-stage3: eb8fd119c65c67f3b1b8268cc7341c22d39b7b61
55
refs/heads/try: d324a424d8f84b1eb049b12cf34182bda91b0024
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/ndm: f3868061cd7988080c30d6d5bf352a5a5fe2460b
8-
refs/heads/try2: bf792b922cb14ed7825246f169d60874f71aec78
8+
refs/heads/try2: 62f98c8ff8179c9754718e62285b82b50dfcfe26
99
refs/heads/incoming: d9317a174e434d4c99fc1a37fd7dc0d2f5328d37
1010
refs/heads/dist-snap: 22efa39382d41b084fde1719df7ae8ce5697d8c9
1111
refs/tags/release-0.2: c870d2dffb391e14efb05aa27898f1f6333a9596

branches/try2/mk/tests.mk

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -93,22 +93,22 @@ cleantestlibs:
9393
| xargs rm -rf
9494

9595
check: cleantestlibs cleantmptestlogs tidy all check-stage2
96-
$(Q)$(S)src/etc/check-summary.py tmp/*.log
96+
$(Q)$(CFG_PYTHON) $(S)src/etc/check-summary.py tmp/*.log
9797

9898
check-notidy: cleantestlibs cleantmptestlogs all check-stage2
99-
$(Q)$(S)src/etc/check-summary.py tmp/*.log
99+
$(Q)$(CFG_PYTHON) $(S)src/etc/check-summary.py tmp/*.log
100100

101101
check-full: cleantestlibs cleantmptestlogs tidy \
102102
all check-stage1 check-stage2 check-stage3
103-
$(Q)$(S)src/etc/check-summary.py tmp/*.log
103+
$(Q)$(CFG_PYTHON) $(S)src/etc/check-summary.py tmp/*.log
104104

105105
check-test: cleantestlibs cleantmptestlogs all check-stage2-rfail
106-
$(Q)$(S)src/etc/check-summary.py tmp/*.log
106+
$(Q)$(CFG_PYTHON) $(S)src/etc/check-summary.py tmp/*.log
107107

108108
check-lite: cleantestlibs cleantmptestlogs rustc-stage2 \
109109
check-stage2-core check-stage2-std check-stage2-rpass \
110110
check-stage2-rfail check-stage2-cfail
111-
$(Q)$(S)src/etc/check-summary.py tmp/*.log
111+
$(Q)$(CFG_PYTHON) $(S)src/etc/check-summary.py tmp/*.log
112112

113113
# Run the tidy script in multiple parts to avoid huge 'echo' commands
114114
ifdef CFG_NOTIDY

branches/try2/src/libsyntax/ast.rs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -744,7 +744,10 @@ enum expr_ {
744744
expr_struct(@path, ~[field], Option<@expr>),
745745

746746
// A vector literal constructed from one repeated element.
747-
expr_repeat(@expr /* element */, @expr /* count */, mutability)
747+
expr_repeat(@expr /* element */, @expr /* count */, mutability),
748+
749+
// No-op: used solely so we can pretty-print faithfully
750+
expr_paren(@expr)
748751
}
749752

750753
#[auto_serialize]

branches/try2/src/libsyntax/fold.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -494,7 +494,8 @@ fn noop_fold_expr(e: expr_, fld: ast_fold) -> expr_ {
494494
expr_struct(fld.fold_path(path),
495495
vec::map(fields, |x| fold_field(*x)),
496496
option::map(&maybe_expr, |x| fld.fold_expr(*x)))
497-
}
497+
},
498+
expr_paren(ex) => expr_paren(fld.fold_expr(ex))
498499
}
499500
}
500501

branches/try2/src/libsyntax/parse/classify.rs

Lines changed: 0 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -36,39 +36,3 @@ fn stmt_ends_with_semi(stmt: ast::stmt) -> bool {
3636
}
3737
}
3838
}
39-
40-
fn need_parens(expr: @ast::expr, outer_prec: uint) -> bool {
41-
match expr.node {
42-
ast::expr_binary(op, _, _) => operator_prec(op) < outer_prec,
43-
ast::expr_cast(_, _) => parse::prec::as_prec < outer_prec,
44-
// This may be too conservative in some cases
45-
ast::expr_assign(_, _) => true,
46-
ast::expr_swap(_, _) => true,
47-
ast::expr_assign_op(_, _, _) => true,
48-
ast::expr_ret(_) => true,
49-
ast::expr_assert(_) => true,
50-
ast::expr_log(_, _, _) => true,
51-
_ => !parse::classify::expr_requires_semi_to_be_stmt(expr)
52-
}
53-
}
54-
55-
fn ends_in_lit_int(ex: @ast::expr) -> bool {
56-
match ex.node {
57-
ast::expr_lit(node) => match node {
58-
@{node: ast::lit_int(_, ast::ty_i), _}
59-
| @{node: ast::lit_int_unsuffixed(_), _} => true,
60-
_ => false
61-
},
62-
ast::expr_binary(_, _, sub) | ast::expr_unary(_, sub) |
63-
ast::expr_copy(sub) | ast::expr_assign(_, sub) |
64-
ast::expr_assign_op(_, _, sub) | ast::expr_swap(_, sub) |
65-
ast::expr_log(_, _, sub) | ast::expr_assert(sub) => {
66-
ends_in_lit_int(sub)
67-
}
68-
ast::expr_fail(osub) | ast::expr_ret(osub) => match osub {
69-
Some(ex) => ends_in_lit_int(ex),
70-
_ => false
71-
},
72-
_ => false
73-
}
74-
}

0 commit comments

Comments
 (0)