Skip to content

Commit 60bd4a5

Browse files
committed
Removed more capture claueses.
1 parent 1f4c758 commit 60bd4a5

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

src/librustc/middle/astencode.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -821,7 +821,7 @@ fn encode_side_tables_for_ii(ecx: @e::encode_ctxt,
821821
let ebml_w = copy ebml_w;
822822
ast_util::visit_ids_for_inlined_item(
823823
ii,
824-
fn@(id: ast::node_id, copy ebml_w) {
824+
fn@(id: ast::node_id) {
825825
// Note: this will cause a copy of ebml_w, which is bad as
826826
// it has mut fields. But I believe it's harmless since
827827
// we generate balanced EBML.

src/libstd/par.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ pub fn mapi<A: Copy Owned, B: Copy Owned>(
107107
{
108108
let slices = map_slices(xs, || {
109109
let f = fn_factory();
110-
fn~(base: uint, slice : &[A], copy f) -> ~[B] {
110+
fn~(base: uint, slice : &[A]) -> ~[B] {
111111
vec::mapi(slice, |i, x| {
112112
f(i + base, x)
113113
})
@@ -126,7 +126,7 @@ pub fn alli<A: Copy Owned>(
126126
{
127127
do vec::all(map_slices(xs, || {
128128
let f = fn_factory();
129-
fn~(base: uint, slice : &[A], copy f) -> bool {
129+
fn~(base: uint, slice : &[A]) -> bool {
130130
vec::alli(slice, |i, x| {
131131
f(i + base, x)
132132
})
@@ -140,7 +140,7 @@ pub fn any<A: Copy Owned>(
140140
fn_factory: &fn() -> ~fn(&A) -> bool) -> bool {
141141
do vec::any(map_slices(xs, || {
142142
let f = fn_factory();
143-
fn~(_base : uint, slice: &[A], copy f) -> bool {
143+
fn~(_base : uint, slice: &[A]) -> bool {
144144
vec::any(slice, |x| f(x))
145145
}
146146
})) |x| { *x }

src/test/compile-fail/kindck-nonsendable-1.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,6 @@ fn foo(_x: @uint) {}
1313
fn main() {
1414
let x = @3u;
1515
let _ = fn~() { foo(x); }; //~ ERROR value has non-owned type `@uint`
16-
let _ = fn~(copy x) { foo(x); }; //~ ERROR value has non-owned type `@uint`
16+
let _ = fn~() { foo(x); }; //~ ERROR value has non-owned type `@uint`
1717
let _ = fn~() { foo(x); }; //~ ERROR value has non-owned type `@uint`
1818
}

0 commit comments

Comments
 (0)