Skip to content

Commit ebfb63b

Browse files
committed
---
yaml --- r: 64381 b: refs/heads/snap-stage3 c: a93244d h: refs/heads/master i: 64379: 0412da0 v: v3
1 parent d3b861e commit ebfb63b

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

43 files changed

+414
-224
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: 2d28d645422c1617be58c8ca7ad9a457264ca850
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
4-
refs/heads/snap-stage3: 827a6d26e62817e39a5b5a71f175557ca221670e
4+
refs/heads/snap-stage3: a93244dbf6a5872a536e8b2727a5ebb94475ebed
55
refs/heads/try: 7b78b52e602bb3ea8174f9b2006bff3315f03ef9
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/ndm: f3868061cd7988080c30d6d5bf352a5a5fe2460b

branches/snap-stage3/doc/tutorial.md

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ supported build environments that are most likely to work.
8484
> know.
8585
8686
[bug-3319]: https://github.com/mozilla/rust/issues/3319
87-
[wiki-start]: https://github.com/mozilla/rust/wiki/Note-getting-started-developing-Rust
87+
[wiki-start]: https://github.com/mozilla/rust/wiki/Note-getting-started-developing-Rust
8888

8989
To build from source you will also need the following prerequisite
9090
packages:
@@ -118,6 +118,7 @@ API-documentation tool; `rustpkg`, the Rust package manager;
118118
`rusti`, the Rust REPL; and `rust`, a tool which acts both as a unified
119119
interface for them, and for a few common command line scenarios.
120120

121+
[wiki-start]: https://github.com/mozilla/rust/wiki/Note-getting-started-developing-Rust
121122
[tarball]: http://static.rust-lang.org/dist/rust-0.7.tar.gz
122123
[win-exe]: http://static.rust-lang.org/dist/rust-0.7-install.exe
123124

@@ -409,6 +410,8 @@ println(fmt!("what is this thing: %?", mystery_object));
409410

410411
You can define your own syntax extensions with the macro system. For details, see the [macro tutorial][macros].
411412

413+
[macros]: tutorial-macros.html
414+
412415
# Control structures
413416

414417
## Conditionals
@@ -1509,6 +1512,8 @@ closures, but they also own them: that is, no other code can access
15091512
them. Owned closures are used in concurrent code, particularly
15101513
for spawning [tasks][tasks].
15111514

1515+
[tasks]: tutorial-tasks.html
1516+
15121517
## Closure compatibility
15131518

15141519
Rust closures have a convenient subtyping property: you can pass any kind of
@@ -2529,4 +2534,9 @@ There is further documentation on the [wiki].
25292534
[ffi]: tutorial-ffi.html
25302535

25312536
[wiki]: https://github.com/mozilla/rust/wiki/Docs
2537+
[unit testing]: https://github.com/mozilla/rust/wiki/Doc-unit-testing
2538+
[rustdoc]: https://github.com/mozilla/rust/wiki/Doc-using-rustdoc
2539+
[cargo]: https://github.com/mozilla/rust/wiki/Doc-using-cargo-to-manage-packages
2540+
[attributes]: https://github.com/mozilla/rust/wiki/Doc-attributes
25322541

2542+
[pound-rust]: http://chat.mibbit.com/?server=irc.mozilla.org&channel=%23rust

branches/snap-stage3/src/libextra/dlist.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -173,11 +173,11 @@ impl<T> Deque<T> for DList<T> {
173173
let tail_own = match tail.prev.resolve() {
174174
None => {
175175
self.list_tail = Rawlink::none();
176-
self.list_head.swap_unwrap()
176+
self.list_head.take_unwrap()
177177
},
178178
Some(tail_prev) => {
179179
self.list_tail = tail.prev;
180-
tail_prev.next.swap_unwrap()
180+
tail_prev.next.take_unwrap()
181181
}
182182
};
183183
Some(tail_own.value)
@@ -465,7 +465,7 @@ impl<'self, A> ListInsertion<A> for MutDListIterator<'self, A> {
465465
Some(prev) => prev,
466466
};
467467
let mut ins_node = ~Node{value: elt, next: None, prev: Rawlink::none()};
468-
let node_own = prev_node.next.swap_unwrap();
468+
let node_own = prev_node.next.take_unwrap();
469469
ins_node.next = link_with_prev(node_own, Rawlink::some(ins_node));
470470
prev_node.next = link_with_prev(ins_node, Rawlink::some(prev_node));
471471
self.list.length += 1;

branches/snap-stage3/src/libextra/net/ip.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ pub fn get_addr(node: &str, iotask: &iotask)
116116
let (output_po, output_ch) = stream();
117117
let mut output_ch = Some(SharedChan::new(output_ch));
118118
do str::as_buf(node) |node_ptr, len| {
119-
let output_ch = output_ch.swap_unwrap();
119+
let output_ch = output_ch.take_unwrap();
120120
debug!("slice len %?", len);
121121
let handle = create_uv_getaddrinfo_t();
122122
let handle_ptr: *uv_getaddrinfo_t = &handle;

branches/snap-stage3/src/libextra/sync.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -260,7 +260,7 @@ impl<'self> Condvar<'self> {
260260
signal_waitqueue(&state.waiters);
261261
}
262262
// Enqueue ourself to be woken up by a signaller.
263-
let SignalEnd = SignalEnd.swap_unwrap();
263+
let SignalEnd = SignalEnd.take_unwrap();
264264
state.blocked[condvar_id].tail.send(SignalEnd);
265265
} else {
266266
out_of_bounds = Some(state.blocked.len());
@@ -281,7 +281,7 @@ impl<'self> Condvar<'self> {
281281
// Unconditionally "block". (Might not actually block if a
282282
// signaller already sent -- I mean 'unconditionally' in contrast
283283
// with acquire().)
284-
let _ = comm::recv_one(WaitEnd.swap_unwrap());
284+
let _ = comm::recv_one(WaitEnd.take_unwrap());
285285
}
286286

287287
// This is needed for a failing condition variable to reacquire the
@@ -353,7 +353,7 @@ impl<'self> Condvar<'self> {
353353
}
354354
}
355355
do check_cvar_bounds(out_of_bounds, condvar_id, "cond.signal_on()") {
356-
let queue = queue.swap_unwrap();
356+
let queue = queue.take_unwrap();
357357
broadcast_waitqueue(&queue)
358358
}
359359
}
@@ -1436,7 +1436,7 @@ mod tests {
14361436
do x.write_downgrade |xwrite| {
14371437
let mut xopt = Some(xwrite);
14381438
do y.write_downgrade |_ywrite| {
1439-
y.downgrade(xopt.swap_unwrap());
1439+
y.downgrade(xopt.take_unwrap());
14401440
error!("oops, y.downgrade(x) should have failed!");
14411441
}
14421442
}

branches/snap-stage3/src/libextra/treemap.rs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -552,7 +552,7 @@ fn mutate_values<'r, K: TotalOrd, V>(node: &'r mut Option<~TreeNode<K, V>>,
552552
// Remove left horizontal link by rotating right
553553
fn skew<K: TotalOrd, V>(node: &mut ~TreeNode<K, V>) {
554554
if node.left.map_default(false, |x| x.level == node.level) {
555-
let mut save = node.left.swap_unwrap();
555+
let mut save = node.left.take_unwrap();
556556
swap(&mut node.left, &mut save.right); // save.right now None
557557
swap(node, &mut save);
558558
node.right = Some(save);
@@ -564,7 +564,7 @@ fn skew<K: TotalOrd, V>(node: &mut ~TreeNode<K, V>) {
564564
fn split<K: TotalOrd, V>(node: &mut ~TreeNode<K, V>) {
565565
if node.right.map_default(false,
566566
|x| x.right.map_default(false, |y| y.level == node.level)) {
567-
let mut save = node.right.swap_unwrap();
567+
let mut save = node.right.take_unwrap();
568568
swap(&mut node.right, &mut save.left); // save.left now None
569569
save.level += 1;
570570
swap(node, &mut save);
@@ -643,7 +643,7 @@ fn remove<K: TotalOrd, V>(node: &mut Option<~TreeNode<K, V>>,
643643
Equal => {
644644
if save.left.is_some() {
645645
if save.right.is_some() {
646-
let mut left = save.left.swap_unwrap();
646+
let mut left = save.left.take_unwrap();
647647
if left.right.is_some() {
648648
heir_swap(save, &mut left.right);
649649
} else {
@@ -653,13 +653,13 @@ fn remove<K: TotalOrd, V>(node: &mut Option<~TreeNode<K, V>>,
653653
save.left = Some(left);
654654
(remove(&mut save.left, key), true)
655655
} else {
656-
let new = save.left.swap_unwrap();
656+
let new = save.left.take_unwrap();
657657
let ~TreeNode{value, _} = replace(save, new);
658-
*save = save.left.swap_unwrap();
658+
*save = save.left.take_unwrap();
659659
(Some(value), true)
660660
}
661661
} else if save.right.is_some() {
662-
let new = save.right.swap_unwrap();
662+
let new = save.right.take_unwrap();
663663
let ~TreeNode{value, _} = replace(save, new);
664664
(Some(value), true)
665665
} else {

branches/snap-stage3/src/librustc/middle/kind.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ fn check_item(item: @item, (cx, visitor): (Context, visit::vt<Context>)) {
122122
None => cx.tcx.sess.bug("trait ref not in def map!"),
123123
Some(&trait_def) => {
124124
let trait_def_id = ast_util::def_id_of_def(trait_def);
125-
if cx.tcx.lang_items.drop_trait() == trait_def_id {
125+
if cx.tcx.lang_items.drop_trait() == Some(trait_def_id) {
126126
// Yes, it's a destructor.
127127
match self_type.node {
128128
ty_path(_, ref bounds, path_node_id) => {

0 commit comments

Comments
 (0)