Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rolling up PRs in the queue #23936

Merged
merged 56 commits into from
Apr 1, 2015
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
56 commits
Select commit Hold shift + click to select a range
62645a1
Fix ICE when dividing integral SIMD types.
hirschenberger Mar 25, 2015
6370f29
std: Stabilize parts of std::os::platform::io
alexcrichton Mar 26, 2015
df65f59
replace deprecated as_slice()
demelev Mar 30, 2015
2a89d69
libcore: Ensure min and max functions are consistent for equal inputs
Ryman Mar 30, 2015
f19e763
std: Stabilize the rest of Any/BoxAny
alexcrichton Mar 30, 2015
e17f4fc
convert: remove FromError, use From<E> instead
seanmonstar Mar 31, 2015
606f50c
Lex binary and octal literals more eagerly.
huonw Mar 30, 2015
a78d383
Update lib.rs
wettowelreactor Mar 31, 2015
edc096d
Document std::borrow with examples
steveklabnik Mar 24, 2015
fe8a660
Last docs for std::env
steveklabnik Mar 31, 2015
5872ae4
Indicate select! is code-like
frewsxcv Mar 31, 2015
5d0beb7
rollup merge of #23549: aturon/stab-num
alexcrichton Mar 31, 2015
03c2f33
rollup merge of #23669: steveklabnik/doc_std_borrow
alexcrichton Mar 31, 2015
9fc51ef
Stabilize `std::convert` and related code
aturon Mar 30, 2015
cf56162
Fix up iterator documentation with regards to for loop sugar
steveklabnik Mar 31, 2015
9ba7974
book: reword timer bit
Mar 31, 2015
d9a6e86
Fixup primitive.str docs
steveklabnik Mar 31, 2015
5cf126a
std: Remove #[old_orphan_check] from PartialEq
alexcrichton Mar 11, 2015
608fff8
rustc: Remove old_orphan_check entirely
alexcrichton Mar 31, 2015
e48c7c6
Fix spelling
steveklabnik Mar 31, 2015
71982aa
std: Add a process::exit function
alexcrichton Mar 31, 2015
b9ab5fe
Stabilize a few remaining stragglers
aturon Mar 31, 2015
1829974
rollup merge of #23704: hirschenberger/simd-intdiv-ice
alexcrichton Mar 31, 2015
890f0ab
rollup merge of #23766: alexcrichton/stabilize-raw-fd
alexcrichton Mar 31, 2015
d03120a
rollup merge of #23876: alexcrichton/stabilize-any
alexcrichton Mar 31, 2015
f6bd6b4
rollup merge of #23878: Ryman/stable_extremes
alexcrichton Mar 31, 2015
095f1fb
rollup merge of #23882: wettowelreactor/patch-2
alexcrichton Mar 31, 2015
5e0bda0
rollup merge of #23885: steveklabnik/doc_std_env
alexcrichton Mar 31, 2015
6d2c640
rollup merge of #23886: demelev/remove_as_slice_usage
alexcrichton Mar 31, 2015
acdb0f9
rollup merge of #23893: frewsxcv/patch-6
alexcrichton Mar 31, 2015
d4a2c94
std: Clean out #[deprecated] APIs
alexcrichton Mar 30, 2015
e3f2d45
rollup merge of #23872: huonw/eager-lexing
alexcrichton Mar 31, 2015
94137a3
Test fixes and rebase conflicts, round 1
alexcrichton Mar 31, 2015
da04788
rollup merge of #23875: aturon/revise-convert-2
alexcrichton Mar 31, 2015
e10ee2c
rollup merge of #23879: seanmonstar/del-from-error
alexcrichton Mar 31, 2015
554946c
rollup merge of #23873: alexcrichton/remove-deprecated
alexcrichton Mar 31, 2015
3053288
Test fixes and rebase conflicts, round 2
alexcrichton Mar 31, 2015
82889f7
rollup merge of #23902: freebroccolo/master
alexcrichton Mar 31, 2015
0cac5b6
rollup merge of #23906: steveklabnik/spellin
alexcrichton Mar 31, 2015
a37311d
rollup merge of #23907: alexcrichton/impl-exit
alexcrichton Mar 31, 2015
30283d4
rollup merge of #23908: aturon/stab-more-stragglers
alexcrichton Mar 31, 2015
3422be3
rollup merge of #23288: alexcrichton/issue-19470
alexcrichton Mar 31, 2015
8da0831
Move benchmark tests to unstable section
steveklabnik Mar 31, 2015
9ab6cc9
rollup merge of #23901: steveklabnik/fix_links_str
alexcrichton Mar 31, 2015
6659865
rollup merge of #23920: steveklabnik/gh23881
alexcrichton Mar 31, 2015
ac77392
std: Stabilize last bits of io::Error
alexcrichton Mar 31, 2015
85e997a
rollup merge of #23899: steveklabnik/gh23851
alexcrichton Mar 31, 2015
50b3ecf
rollup merge of #23919: alexcrichton/stabilize-io-error
alexcrichton Mar 31, 2015
55e531d
Add test for #17746
aturon Mar 31, 2015
371ba00
Add description of + for multiple trait bounds
steveklabnik Mar 31, 2015
72f5973
Test fixes and rebase conflicts, round 3
alexcrichton Mar 31, 2015
4f643d7
rollup merge of #23863: pnkfelix/arith-oflo-const-eval
alexcrichton Apr 1, 2015
1d5ef75
rollup merge of #23921: aturon/issue-17746
alexcrichton Apr 1, 2015
6ebb6e6
rollup merge of #23923: steveklabnik/gh23688
alexcrichton Apr 1, 2015
8dff0ac
Test fixes and rebase conflicts
alexcrichton Apr 1, 2015
2b71aed
Update android tests to reflect API switch from `os::env` to `env::va…
pnkfelix Apr 1, 2015
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Test fixes and rebase conflicts, round 3
  • Loading branch information
alexcrichton committed Apr 1, 2015
commit 72f59732d7974767650abfc58f8287212e5a1fba
1 change: 0 additions & 1 deletion src/liballoc/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,6 @@
#![feature(unsafe_no_drop_flag, filling_drop)]
#![feature(core)]
#![feature(unique)]
#![feature(convert)]
#![cfg_attr(test, feature(test, alloc, rustc_private))]
#![cfg_attr(all(not(feature = "external_funcs"), not(feature = "external_crate")),
feature(libc))]
Expand Down
24 changes: 13 additions & 11 deletions src/libcollections/str.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,10 @@

//! Unicode string manipulation (the `str` type).
//!
//! Rust's `str` type is one of the core primitive types of the language. `&str` is the borrowed
//! string type. This type of string can only be created from other strings, unless it is a
//! `&'static str` (see below). It is not possible to move out of borrowed strings because they are
//! owned elsewhere.
//! Rust's `str` type is one of the core primitive types of the language. `&str`
//! is the borrowed string type. This type of string can only be created from
//! other strings, unless it is a `&'static str` (see below). It is not possible
//! to move out of borrowed strings because they are owned elsewhere.
//!
//! # Examples
//!
Expand All @@ -25,8 +25,9 @@
//! let s = "Hello, world.";
//! ```
//!
//! This `&str` is a `&'static str`, which is the type of string literals. They're `'static`
//! because literals are available for the entire lifetime of the program.
//! This `&str` is a `&'static str`, which is the type of string literals.
//! They're `'static` because literals are available for the entire lifetime of
//! the program.
//!
//! You can get a non-`'static` `&str` by taking a slice of a `String`:
//!
Expand All @@ -37,12 +38,13 @@
//!
//! # Representation
//!
//! Rust's string type, `str`, is a sequence of Unicode scalar values encoded as a stream of UTF-8
//! bytes. All [strings](../../reference.html#literals) are guaranteed to be validly encoded UTF-8
//! sequences. Additionally, strings are not null-terminated and can thus contain null bytes.
//! Rust's string type, `str`, is a sequence of Unicode scalar values encoded as
//! a stream of UTF-8 bytes. All [strings](../../reference.html#literals) are
//! guaranteed to be validly encoded UTF-8 sequences. Additionally, strings are
//! not null-terminated and can thus contain null bytes.
//!
//! The actual representation of `str`s have direct mappings to slices: `&str` is the same as
//! `&[u8]`.
//! The actual representation of `str`s have direct mappings to slices: `&str`
//! is the same as `&[u8]`.

#![doc(primitive = "str")]
#![stable(feature = "rust1", since = "1.0.0")]
Expand Down
3 changes: 2 additions & 1 deletion src/libcore/iter.rs
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,11 @@
//! }
//!
//! // Rough translation of the iteration without a `for` iterator.
//! # let values = vec![1, 2, 3];
//! let mut it = values.into_iter();
//! loop {
//! match it.next() {
//! Some(&x) => {
//! Some(x) => {
//! println!("{}", x);
//! }
//! None => { break }
Expand Down
1 change: 0 additions & 1 deletion src/librbml/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,6 @@
html_root_url = "http://doc.rust-lang.org/nightly/",
html_playground_url = "http://play.rust-lang.org/")]

#![feature(io)]
#![feature(core)]
#![feature(rustc_private)]
#![feature(staged_api)]
Expand Down
1 change: 0 additions & 1 deletion src/librustc/middle/ty.rs
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,6 @@ use std::cmp;
use std::fmt;
use std::hash::{Hash, SipHasher, Hasher};
use std::mem;
use std::num::ToPrimitive;
use std::ops;
use std::rc::Rc;
use std::vec::IntoIter;
Expand Down
44 changes: 22 additions & 22 deletions src/libstd/io/buffered.rs
Original file line number Diff line number Diff line change
Expand Up @@ -503,34 +503,34 @@ mod tests {

let mut buf = [0, 0, 0];
let nread = reader.read(&mut buf);
assert_eq!(Ok(3), nread);
assert_eq!(nread.unwrap(), 3);
let b: &[_] = &[5, 6, 7];
assert_eq!(buf, b);

let mut buf = [0, 0];
let nread = reader.read(&mut buf);
assert_eq!(Ok(2), nread);
assert_eq!(nread.unwrap(), 2);
let b: &[_] = &[0, 1];
assert_eq!(buf, b);

let mut buf = [0];
let nread = reader.read(&mut buf);
assert_eq!(Ok(1), nread);
assert_eq!(nread.unwrap(), 1);
let b: &[_] = &[2];
assert_eq!(buf, b);

let mut buf = [0, 0, 0];
let nread = reader.read(&mut buf);
assert_eq!(Ok(1), nread);
assert_eq!(nread.unwrap(), 1);
let b: &[_] = &[3, 0, 0];
assert_eq!(buf, b);

let nread = reader.read(&mut buf);
assert_eq!(Ok(1), nread);
assert_eq!(nread.unwrap(), 1);
let b: &[_] = &[4, 0, 0];
assert_eq!(buf, b);

assert_eq!(reader.read(&mut buf), Ok(0));
assert_eq!(reader.read(&mut buf).unwrap(), 0);
}

#[test]
Expand Down Expand Up @@ -592,7 +592,7 @@ mod tests {
}

let mut stream = BufStream::new(S);
assert_eq!(stream.read(&mut [0; 10]), Ok(0));
assert_eq!(stream.read(&mut [0; 10]).unwrap(), 0);
stream.write(&[0; 10]).unwrap();
stream.flush().unwrap();
}
Expand Down Expand Up @@ -658,41 +658,41 @@ mod tests {
let in_buf: &[u8] = b"a\nb\nc";
let reader = BufReader::with_capacity(2, in_buf);
let mut it = reader.lines();
assert_eq!(it.next(), Some(Ok("a".to_string())));
assert_eq!(it.next(), Some(Ok("b".to_string())));
assert_eq!(it.next(), Some(Ok("c".to_string())));
assert_eq!(it.next(), None);
assert_eq!(it.next().unwrap().unwrap(), "a".to_string());
assert_eq!(it.next().unwrap().unwrap(), "b".to_string());
assert_eq!(it.next().unwrap().unwrap(), "c".to_string());
assert!(it.next().is_none());
}

#[test]
fn test_short_reads() {
let inner = ShortReader{lengths: vec![0, 1, 2, 0, 1, 0]};
let mut reader = BufReader::new(inner);
let mut buf = [0, 0];
assert_eq!(reader.read(&mut buf), Ok(0));
assert_eq!(reader.read(&mut buf), Ok(1));
assert_eq!(reader.read(&mut buf), Ok(2));
assert_eq!(reader.read(&mut buf), Ok(0));
assert_eq!(reader.read(&mut buf), Ok(1));
assert_eq!(reader.read(&mut buf), Ok(0));
assert_eq!(reader.read(&mut buf), Ok(0));
assert_eq!(reader.read(&mut buf).unwrap(), 0);
assert_eq!(reader.read(&mut buf).unwrap(), 1);
assert_eq!(reader.read(&mut buf).unwrap(), 2);
assert_eq!(reader.read(&mut buf).unwrap(), 0);
assert_eq!(reader.read(&mut buf).unwrap(), 1);
assert_eq!(reader.read(&mut buf).unwrap(), 0);
assert_eq!(reader.read(&mut buf).unwrap(), 0);
}

#[test]
fn read_char_buffered() {
let buf = [195, 159];
let reader = BufReader::with_capacity(1, &buf[..]);
assert_eq!(reader.chars().next(), Some(Ok('ß')));
assert_eq!(reader.chars().next().unwrap().unwrap(), 'ß');
}

#[test]
fn test_chars() {
let buf = [195, 159, b'a'];
let reader = BufReader::with_capacity(1, &buf[..]);
let mut it = reader.chars();
assert_eq!(it.next(), Some(Ok('ß')));
assert_eq!(it.next(), Some(Ok('a')));
assert_eq!(it.next(), None);
assert_eq!(it.next().unwrap().unwrap(), 'ß');
assert_eq!(it.next().unwrap().unwrap(), 'a');
assert!(it.next().is_none());
}

#[test]
Expand Down
Loading