about summary refs log tree commit diff
path: root/src/libstd
AgeCommit message (Collapse)AuthorLines
2015-02-10Auto merge of #21936 - alexcrichton:fsv2, r=aturonbors-13/+2564
This commit is an implementation of [RFC 739][rfc] which adds a new `std::fs` module to the standard library. This module provides much of the same functionality as `std::old_io::fs` but it has many tweaked APIs as well as uses the new `std::path` module. [rfc]: https://github.com/rust-lang/rfcs/pull/739
2015-02-09std: Add a new `fs` moduleAlex Crichton-13/+2564
This commit is an implementation of [RFC 739][rfc] which adds a new `std::fs` module to the standard library. This module provides much of the same functionality as `std::old_io::fs` but it has many tweaked APIs as well as uses the new `std::path` module. [rfc]: https://github.com/rust-lang/rfcs/pull/739
2015-02-09std: Rename IntoIterator::Iter to IntoIterAlex Crichton-5/+5
This is in preparation for stabilization of the `IntoIterator` trait. All implementations and references to `Iter` need to be renamed to `IntoIter`. [breaking-change]
2015-02-09Update deprecation notice.Pierre Baillet-1/+1
- add namespace - add function parens
2015-02-08Rename Show to Debug, String to DisplayAlexander Korolkov-3/+3
Update reference.md: - derive() no longer supports Zero trait - derive() now supports Copy trait
2015-02-08Move native thread name setting from thread_info to Thread, fixes #21911Vojtech Kral-4/+4
2015-02-08Auto merge of #22046 - mneumann:dragonfly-libstd-fixes, r=huonwbors-1/+3
2015-02-08Correct fns exp2 that were calling expCarol Nichols-2/+56
Fixes #22080.
2015-02-08Auto merge of #21565 - kmcallister:poison, r=alexcrichtonbors-12/+40
I needed these to implement efficient poisoning in [seqloq](https://github.com/kmcallister/seqloq/tree/poison).
2015-02-07Make std::fmt a simple re-export from collectionsKeegan McAllister-415/+1
2015-02-07Feature-gate #![no_std]Keegan McAllister-0/+1
Fixes #21833. [breaking-change]
2015-02-07Don't use std:: paths in syntax extensions when compiling a #![no_std] crateKeegan McAllister-29/+10
Fixes #16803. Fixes #14342. Fixes half of #21827 -- slice syntax is still broken.
2015-02-07Fix struct passwd and _SC_GETPW_R_SIZE_MAX for DragonFlyMichael Neumann-1/+3
2015-02-06sync: Expose PoisonError::newKeegan McAllister-12/+14
2015-02-06sync: Add is_poisoned to Mutex and RwLockKeegan McAllister-0/+26
2015-02-06make `IndexMut` a super trait over `Index`Jorge Aparicio-2/+0
closes #21630
2015-02-07fix outdated docsAlexis-28/+28
Conflicts: src/libstd/collections/mod.rs
2015-02-07fix outdated docsAlexis-9/+9
Conflicts: src/libstd/collections/mod.rs
2015-02-06More libcollections fixesManish Goregaokar-3/+3
2015-02-06Rollup merge of #21991 - steveklabnik:gh21915, r=huonwManish Goregaokar-1/+1
Fixes #21915
2015-02-06Rollup merge of #21926 - mzabaluev:raw-lifetime, r=alexcrichtonManish Goregaokar-8/+7
New functions, `slice::from_raw_parts` and `slice::from_raw_parts_mut`, are added to implement the lifetime convention as agreed in rust-lang/rfcs#556. The functions `slice::from_raw_buf` and `slice::from_raw_mut_buf` are left deprecated for the time being. Holding back on changing the signature of `std::ffi::c_str_to_bytes` as consensus in rust-lang/rfcs#592 is building to replace it with a composition of other functions. Contribution to #21923.
2015-02-06Rollup merge of #21969 - Gankro:collections-cleanup, r=alexcrichtonManish Goregaokar-124/+124
This is 99% burning ints to the ground, but I also got rid of useless annotations or made code more \"idiomatic\" as I went along. Mostly changes in tests.
2015-02-06Rollup merge of #21924 - steveklabnik:fix_try_docs, r=huonwManish Goregaokar-2/+2
This is now a Result, not an Option.
2015-02-06Rollup merge of #21925 - sfackler:allow-missing-copy, r=alexcrichtonManish Goregaokar-11/+0
This was particularly helpful in the time just after OIBIT's implementation to make sure things that were supposed to be Copy continued to be, but it's now creates a lot of noise for types that intentionally don't want to be Copy. r? @alexcrichton
2015-02-06Rollup merge of #21951 - Gankro:entry, r=aturonManish Goregaokar-8/+8
This also removes two erroneous re-exports of the Entry variants, and so is incidentally a [breaking-change], though presumably no one should have been using those. r? @aturon
2015-02-06Rollup merge of #21954 - jbcrail:fix-misspelled-comments, r=steveklabnikManish Goregaokar-11/+11
The spelling corrections were made in both documentation comments and regular comments.
2015-02-06Rollup merge of #21964 - semarie:openbsd-env, r=alexcrichtonManish Goregaokar-14/+48
- add `_SC_GETPW_R_SIZE_MAX` constant - declare `struct passwd` - convert `load_self` to `current_exe` Note: OpenBSD don't provide system function to return a valuable Path for `env::current_exe`. The implementation is currently based on the value of `argv[0]`, which couldn't be used when executable is called via PATH.
2015-02-05Mention the queueueue-ness of mpsc.Steve Klabnik-1/+1
Fixes #21915
2015-02-05Use `for` instead of `while` in ascii.rs testsKevin Yap-19/+7
2015-02-05misc collections code cleanupAlexis-124/+124
2015-02-05cleanup: replace `as[_mut]_slice()` calls with deref coercionsJorge Aparicio-170/+168
2015-02-05complete openbsd support for `std::env`Sébastien Marie-7/+37
- add `std::env:consts` - deprecating `std::os::consts` - refactoring errno_location()
2015-02-05unbreak tree for openbsd after #21787Sébastien Marie-7/+11
- add `_SC_GETPW_R_SIZE_MAX` constant - declare `struct passwd` - convert `load_self` to `current_exe` Note: OpenBSD don't provide system function to return a valuable Path for `env::current_exe`. The implementation is currently based on the value of `argv[0]`, which couldn't be used when executable is called via PATH.
2015-02-05Replace one more slice::from_raw_mut_buf added with new ioMikhail Zabaluev-3/+2
2015-02-05Replace usage of slice::from_raw_buf with slice::from_raw_partsMikhail Zabaluev-5/+5
New functions, slice::from_raw_parts and slice::from_raw_parts_mut, are added to implement the lifetime convention as agreed in RFC PR #556. The functions slice::from_raw_buf and slice::from_raw_mut_buf are left deprecated for the time being.
2015-02-04Remove unnecessary type casts.Jormundir-3/+3
2015-02-04Fix for misspelled comments.Joseph Crail-11/+11
The spelling corrections were made in both documentation comments and regular comments.
2015-02-04remove all kind annotations from closuresJorge Aparicio-38/+38
2015-02-04stabilize core Entry APIAlexis-8/+8
2015-02-04std: Add reexports for core parse errorsAlex Crichton-1/+1
These were forgotten reexports from #21718 Closes #21929
2015-02-04Auto merge of #21544 - P1start:mangle-unicode, r=alexcrichtonbors-15/+15
`{` and `}` aren’t valid characters on ARM, so this makes Unicode characters render as, e.g., `$u38d$` instead of `$u{38d}`. This also fixes a small bug where `)` (**r**ight **p**arenthesis) and `*` (**r**aw **p**ointer) would both mangle to `$RP$`, making `)` show up as `*` in backtraces.
2015-02-04std::os::errno returns platform specific value. fixes #21898Jormundir-9/+9
2015-02-04Auto merge of #21892 - huonw:deprecate-rand, r=alexcrichtonbors-1/+12
Use [`rand`](https://crates.io/crates/rand) and [`derive_rand`](https://crates.io/crates/derive_rand) from crates.io. [breaking-change]
2015-02-03Switch missing_copy_implementations to default-allowSteven Fackler-11/+0
This was particularly helpful in the time just after OIBIT's implementation to make sure things that were supposed to be Copy continued to be, but it's now creates a lot of noise for types that intentionally don't want to be Copy.
2015-02-04Fix issue with rt::unwind::try() docsSteve Klabnik-2/+2
This is now a Result, not an Option.
2015-02-03Test fixes and rebase conflictsAlex Crichton-14/+24
2015-02-03rollup merge of #21910: Manishearth/missing_stabilityAlex Crichton-0/+1
Currently, if a `#![staged_api]` crate contains an exported item without a stability marker (or inherited stability), the item is useless. This change introduces a check to ensure that all exported items have a defined stability. it also introduces the `unmarked_api` feature, which lets users import unmarked features. While this PR should in theory forbid these from existing, in practice we can't be so sure; so this lets users bypass this check instead of having to wait for the library and/or compiler to be fixed (since otherwise this is a hard error). r? @aturon
2015-02-03rollup merge of #21893: vhbit/ios-build-fixAlex Crichton-14/+17
2015-02-04Fix Unicode name manglingP1start-15/+15
`{` and `}` aren’t valid characters on ARM. This also fixes a small bug where `)` (**r**ight **p**arenthesis) and `*` (**r**aw **p**ointer) would both mangle to `$RP$`, making `)` show up as `*` in backtraces.
2015-02-03rollup merge of #21835: alexcrichton/iov2Alex Crichton-4/+2546
This commit is an implementation of [RFC 576][rfc] which adds back the `std::io` module to the standard library. No functionality in `std::old_io` has been deprecated just yet, and the new `std::io` module is behind the same `io` feature gate. [rfc]: https://github.com/rust-lang/rfcs/pull/576 A good bit of functionality was copied over from `std::old_io`, but many tweaks were required for the new method signatures. Behavior such as precisely when buffered objects call to the underlying object may have been tweaked slightly in the transition. All implementations were audited to use composition wherever possible. For example the custom `pos` and `cap` cursors in `BufReader` were removed in favor of just using `Cursor<Vec<u8>>`. A few liberties were taken during this implementation which were not explicitly spelled out in the RFC: * The old `LineBufferedWriter` is now named `LineWriter` * The internal representation of `Error` now favors OS error codes (a 0-allocation path) and contains a `Box` for extra semantic data. * The io prelude currently reexports `Seek` as `NewSeek` to prevent conflicts with the real prelude reexport of `old_io::Seek` * The `chars` method was moved from `BufReadExt` to `ReadExt`. * The `chars` iterator returns a custom error with a variant that explains that the data was not valid UTF-8.