Skip to content

Commit 825c0e7

Browse files
committed
---
yaml --- r: 48586 b: refs/heads/snap-stage3 c: 98ce99d h: refs/heads/master v: v3
1 parent eed5ef7 commit 825c0e7

File tree

3 files changed

+29
-11
lines changed

3 files changed

+29
-11
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
refs/heads/master: 3bbcac322669cff3abde5be937cc4ec3860f3985
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
4-
refs/heads/snap-stage3: 06a336ae791ea8a8e618ff43a97b1e6e510c6601
4+
refs/heads/snap-stage3: 98ce99d500b13c79fd8e74e807167d8a59caf0e7
55
refs/heads/try: 2a8fb58d79e685d5ca07b039badcf2ae3ef077ea
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/ndm: f3868061cd7988080c30d6d5bf352a5a5fe2460b

branches/snap-stage3/src/etc/kate/rust.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@
1717
</list>
1818
<list name="keywords">
1919
<item> as </item>
20-
<item> assert </item>
2120
<item> break </item>
2221
<item> const </item>
2322
<item> copy </item>
@@ -69,6 +68,7 @@
6968
<item> Shl </item>
7069
<item> Shr </item>
7170
<item> Index </item>
71+
<item> Not </item>
7272
</list>
7373
<list name="types">
7474
<item> bool </item>

branches/snap-stage3/src/libcore/vec.rs

Lines changed: 27 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -2268,27 +2268,45 @@ pub mod bytes {
22682268

22692269
// ___________________________________________________________________________
22702270
// ITERATION TRAIT METHODS
2271+
//
2272+
// This cannot be used with iter-trait.rs because of the region pointer
2273+
// required in the slice.
22712274

22722275
impl<A> iter::BaseIter<A> for &self/[A] {
2273-
#[inline(always)]
2274-
pure fn each(&self, blk: fn(v: &'self A) -> bool) { each(*self, blk) }
2275-
#[inline(always)]
2276+
pub pure fn each(&self, blk: fn(v: &A) -> bool) {
2277+
// FIXME(#2263)---should be able to call each(self, blk)
2278+
for each(*self) |e| {
2279+
if (!blk(e)) {
2280+
return;
2281+
}
2282+
}
2283+
}
22762284
pure fn size_hint(&self) -> Option<uint> { Some(len(*self)) }
22772285
}
22782286

22792287
// FIXME(#4148): This should be redundant
22802288
impl<A> iter::BaseIter<A> for ~[A] {
2281-
#[inline(always)]
2282-
pure fn each(&self, blk: fn(v: &'self A) -> bool) { each(*self, blk) }
2283-
#[inline(always)]
2289+
pub pure fn each(&self, blk: fn(v: &A) -> bool) {
2290+
// FIXME(#2263)---should be able to call each(self, blk)
2291+
for each(*self) |e| {
2292+
if (!blk(e)) {
2293+
return;
2294+
}
2295+
}
2296+
}
22842297
pure fn size_hint(&self) -> Option<uint> { Some(len(*self)) }
22852298
}
22862299

22872300
// FIXME(#4148): This should be redundant
22882301
impl<A> iter::BaseIter<A> for @[A] {
2289-
#[inline(always)]
2290-
pure fn each(&self, blk: fn(v: &'self A) -> bool) { each(*self, blk) }
2291-
#[inline(always)]
2302+
pub pure fn each(&self, blk: fn(v: &A) -> bool) {
2303+
// FIXME(#2263)---should be able to call each(self, blk)
2304+
for each(*self) |e| {
2305+
if (!blk(e)) {
2306+
return;
2307+
}
2308+
}
2309+
}
22922310
pure fn size_hint(&self) -> Option<uint> { Some(len(*self)) }
22932311
}
22942312

0 commit comments

Comments
 (0)