Skip to content

Commit 3c2659e

Browse files
committed
---
yaml --- r: 147647 b: refs/heads/try2 c: 7cb234b h: refs/heads/master i: 147645: 2e09afd 147643: 8c924be 147639: b27a571 147631: 9257fa9 147615: b09e38d 147583: a99a75c v: v3
1 parent 6d057e6 commit 3c2659e

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
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: 78a7676898d9f80ab540c6df5d4c9ce35bb50463
55
refs/heads/try: 519addf6277dbafccbb4159db4b710c37eaa2ec5
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/ndm: f3868061cd7988080c30d6d5bf352a5a5fe2460b
8-
refs/heads/try2: d0dfc35fc906e30502c17139ac91798db4d99fce
8+
refs/heads/try2: 7cb234bee9dcb411031d4a0b960b2096258aa6ad
99
refs/heads/dist-snap: ba4081a5a8573875fed17545846f6f6902c8ba8d
1010
refs/tags/release-0.2: c870d2dffb391e14efb05aa27898f1f6333a9596
1111
refs/tags/release-0.3: b5f0d0f648d9a6153664837026ba1be43d3e2503

branches/try2/src/librustc/front/test.rs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ pub fn modify_for_testing(sess: session::Session,
6363
}
6464

6565
struct TestHarnessGenerator {
66-
cx: @mut TestCtxt,
66+
cx: @TestCtxt,
6767
}
6868

6969
impl fold::ast_fold for TestHarnessGenerator {
@@ -126,7 +126,7 @@ impl fold::ast_fold for TestHarnessGenerator {
126126
// Remove any #[main] from the AST so it doesn't clash with
127127
// the one we're going to add. Only if compiling an executable.
128128

129-
fn nomain(cx: @mut TestCtxt, item: @ast::item) -> @ast::item {
129+
fn nomain(cx: @TestCtxt, item: @ast::item) -> @ast::item {
130130
if !*cx.sess.building_library {
131131
@ast::item {
132132
attrs: item.attrs.iter().filter_map(|attr| {
@@ -154,7 +154,7 @@ impl fold::ast_fold for TestHarnessGenerator {
154154

155155
fn generate_test_harness(sess: session::Session, crate: ast::Crate)
156156
-> ast::Crate {
157-
let cx: @mut TestCtxt = @mut TestCtxt {
157+
let cx: @TestCtxt = @TestCtxt {
158158
sess: sess,
159159
ext_cx: ExtCtxt::new(sess.parse_sess, sess.opts.cfg.clone()),
160160
path: RefCell::new(~[]),
@@ -190,7 +190,7 @@ fn strip_test_functions(crate: ast::Crate) -> ast::Crate {
190190
})
191191
}
192192

193-
fn is_test_fn(cx: @mut TestCtxt, i: @ast::item) -> bool {
193+
fn is_test_fn(cx: @TestCtxt, i: @ast::item) -> bool {
194194
let has_test_attr = attr::contains_name(i.attrs, "test");
195195

196196
fn has_test_signature(i: @ast::item) -> bool {
@@ -243,7 +243,7 @@ fn is_bench_fn(i: @ast::item) -> bool {
243243
return has_bench_attr && has_test_signature(i);
244244
}
245245

246-
fn is_ignored(cx: @mut TestCtxt, i: @ast::item) -> bool {
246+
fn is_ignored(cx: @TestCtxt, i: @ast::item) -> bool {
247247
i.attrs.iter().any(|attr| {
248248
// check ignore(cfg(foo, bar))
249249
"ignore" == attr.name() && match attr.meta_item_list() {

0 commit comments

Comments
 (0)