about summary refs log tree commit diff
path: root/src/libcore
AgeCommit message (Collapse)AuthorLines
2015-04-21rollup merge of #24661: SimonSapin/fmt-write-charAlex Crichton-0/+17
as accepted in [RFC 526](https://github.com/rust-lang/rfcs/blob/master/text/0526-fmt-text-writer.md). Note that this brand new method is marked as **stable**. I judged this safe enough: it’s simple enough that it’s very unlikely to change. Still, I can mark it unstable instead if you prefer. r? @alexcrichton
2015-04-21Pick a feature name for write_charSimon Sapin-1/+1
2015-04-21write_char is unlikely to make it for 1.0, it’ll be 1.1Simon Sapin-1/+1
2015-04-21Auto merge of #24620 - pczarn:model-lexer-issues, r=cmrbors-6/+0
Fixes #15679 Fixes #15878 Fixes #15882 Closes #15883
2015-04-21Add a `write_char` method to `std::fmt::Write`Simon Sapin-0/+17
as accepted in [RFC 526](https://github.com/rust-lang/rfcs/blob/master/text/0526-fmt-text-writer.md).
2015-04-21Model lexer: Fix remaining issuesPiotr Czarnecki-6/+0
2015-04-20Rollup merge of #24628 - steveklabnik:gh24173, r=alexcrichtonSteve Klabnik-21/+0
Fixes #24173 These docs could all use examples, so for now, let's just remove the bad one, and when I go over this whole module I'll put in better ones.
2015-04-20Rollup merge of #24627 - steveklabnik:gh24008, r=alexcrichtonSteve Klabnik-13/+13
Fixes #24008.
2015-04-20Auto merge of #24606 - bombless:doc-result, r=alexcrichtonbors-2/+2
Get rid of the confusion that what does "custom" mean in this context.
2015-04-20remove bad example from PartialEq docsSteve Klabnik-21/+0
Fixes #24173
2015-04-20Make iterator struct docs more consistent.Steve Klabnik-13/+13
Fixes #24008.
2015-04-20Improve doc for `Result::unwrap()`York Xiang-2/+2
2015-04-18Indicate keywords are code-like in Fuse::reset_fuse doc commentCorey Farwell-2/+3
2015-04-18Auto merge of #24428 - kwantam:deprecate_unicode_fns, r=alexcrichtonbors-1/+1
This patch 1. renames libunicode to librustc_unicode, 2. deprecates several pieces of libunicode (see below), and 3. removes references to deprecated functions from librustc_driver and libsyntax. This may change pretty-printed output from these modules in cases involving wide or combining characters used in filenames, identifiers, etc. The following functions are marked deprecated: 1. char.width() and str.width(): --> use unicode-width crate 2. str.graphemes() and str.grapheme_indices(): --> use unicode-segmentation crate 3. str.nfd_chars(), str.nfkd_chars(), str.nfc_chars(), str.nfkc_chars(), char.compose(), char.decompose_canonical(), char.decompose_compatible(), char.canonical_combining_class(): --> use unicode-normalization crate
2015-04-17Auto merge of #24500 - pnkfelix:oflo-checked-neg, r=nikomatsakisbors-1/+5
Add conditional overflow-checking to signed negate operator. I argue this can land independently of #24420 , because one can write the implementation of `wrapped_neg()` inline if necessary (as illustrated in two cases on this PR). This needs to go into beta channel.
2015-04-17Rollup merge of #24491 - bluss:rangefull-debug, r=huonwManish Goregaokar-1/+1
Fix Debug impl for RangeFull The Debug impl was using quotes, which was inconsistent: => (.., 1.., 2..3, ..4) (\"..\", 1.., 2..3, ..4) Fix to use just ..
2015-04-17side-step potentially panic'ing negate in `fn abs`.Felix S. Klock II-1/+5
2015-04-17Auto merge of #24512 - steveklabnik:rollup, r=steveklabnikbors-9/+9
- Successful merges: #23782, #24455, #24490, #24493, #24494, #24496, #24498, #24499, #24501, #24502, #24506, #24507, #24508, #24509, #24510 - Failed merges: #24488
2015-04-16Fix broken links in the docsFlorian Hartwig-4/+4
2015-04-16Indicate None is code-like in doc commentsCorey Farwell-5/+5
2015-04-17Auto merge of #24420 - pnkfelix:oflo-api, r=alexcrichtonbors-1/+156
Fill in missing parts of Integer overflow API See todo list at #22020
2015-04-16deprecate Unicode functions that will be moved to crates.iokwantam-1/+1
This patch 1. renames libunicode to librustc_unicode, 2. deprecates several pieces of libunicode (see below), and 3. removes references to deprecated functions from librustc_driver and libsyntax. This may change pretty-printed output from these modules in cases involving wide or combining characters used in filenames, identifiers, etc. The following functions are marked deprecated: 1. char.width() and str.width(): --> use unicode-width crate 2. str.graphemes() and str.grapheme_indices(): --> use unicode-segmentation crate 3. str.nfd_chars(), str.nfkd_chars(), str.nfc_chars(), str.nfkc_chars(), char.compose(), char.decompose_canonical(), char.decompose_compatible(), char.canonical_combining_class(): --> use unicode-normalization crate
2015-04-16Fix Debug impl for RangeFullUlrik Sverdrup-1/+1
The Debug impl was using quotes, which was inconsistent: => (.., 1.., 2..3, ..4) ("..", 1.., 2..3, ..4) Fix to use just ..
2015-04-16Auto merge of #23682 - tamird:DRY-is-empty, r=alexcrichtonbors-13/+13
r? @alexcrichton
2015-04-15Rollup merge of #24465 - steveklabnik:intoiteratordocfix, r=alexcrichtonSteve Klabnik-1/+1
2015-04-15Rollup merge of #24440 - nham:improve_enumerate_doc, r=alexcrichtonSteve Klabnik-2/+3
I found that the current description of `enumerate()` doesn't actually tell you what, specifically, the method does, and you have to look at the example to figure it out. Here's a description that I think is better.
2015-04-15Rollup merge of #24435 - killercup:patch-9, r=steveklabnikSteve Klabnik-3/+3
The link works on the `std/ptr/index.html` docs page, but not the `std/primitive.pointer.html` page. Instead of leaving it half-broken, it is removed. I tried fixing this in #24432, but @alexcrichton mentioned that this doc string was used in two places (with different base paths unfortunately). r? @alexcrichton
2015-04-15Describe the Iterator enumerate() method more clearly.Nick Hamann-2/+3
2015-04-15Fix link in intoiterator docsSteve Klabnik-1/+1
2015-04-14Negative case of `len()` -> `is_empty()`Tamir Duberstein-2/+2
`s/([^\(\s]+\.)len\(\) [(?:!=)>] 0/!$1is_empty()/g`
2015-04-14Positive case of `len()` -> `is_empty()`Tamir Duberstein-11/+11
`s/(?<!\{ self)(?<=\.)len\(\) == 0/is_empty()/g`
2015-04-14Remove Incorrect Link from std::ptr::null DocsPascal Hertleif-3/+3
The link works on the std::ptr docs page, but not the primitive.ptr.html page. Instead of leaving it half-broken, it is removed.
2015-04-14rollup merge of #24377: apasel422/docsAlex Crichton-113/+113
Conflicts: src/libstd/net/ip.rs src/libstd/sys/unix/fs.rs src/libstd/sys/unix/mod.rs src/libstd/sys/windows/mod.rs
2015-04-14rollup merge of #24379: rkruppe/fmt-negative-zeroAlex Crichton-114/+52
Fixes #20596 by making `Debug` render negative zero with a `-` without affecting the behavior of `Display`. While I was at it, I also removed some dead code from `float_to_str_bytes_common` (the one from `libcore/fmt/float.rs`, not the function of the same name in `libstd/num/strconv.rs`). It had support for different bases, and for negative numbers, but the function is internal to core and the couple places that call it (all in `libcore/fmt/mod.rs`) never use those features: They pass in `num.abs()` and base 10.
2015-04-14rollup merge of #24329: GuillaumeGomez/atomicboolAlex Crichton-0/+20
Fixes #24319.
2015-04-14rollup merge of #24310: alexcrichton/stabilize-utf8-errorAlex Crichton-22/+17
The meaning of each variant of this enum was somewhat ambiguous and it's uncler that we wouldn't even want to add more enumeration values in the future. As a result this error has been altered to instead become an opaque structure. Learning about the "first invalid byte index" is still an unstable feature, but the type itself is now stable.
2015-04-14rollup merge of #24303: alexcrichton/remove-deprecatedAlex Crichton-70/+52
This commit removes these long deprecated modules. Such a nice diff stat!
2015-04-14rollup merge of #24048: frewsxcv/patch-11Alex Crichton-1/+1
Since it doesn't utilize the parameter, it's not very idiomatic since it could just use the `Result::or` method. So this changes the example to utilize the parameter. As far as I can tell, all the numbers in this example are completely arbitrary.
2015-04-14core: Update all Result docsAlex Crichton-70/+52
2015-04-14Fix bug in `wrapping_div`Felix S. Klock II-1/+1
See discussion, albeit one-sided, in: https://github.com/rust-lang/rfcs/issues/964
2015-04-14Auto merge of #24312 - rprichard:destabilize-format-args, r=alexcrichtonbors-29/+36
Fixes #22953.
2015-04-14Remaining API additions for int overflow:Felix S. Klock II-0/+155
`wrapping_div`, `wrapping_rem`, `wrapping_neg`, `wrapping_shl`, `wrapping_shr`. All marked unstable under `core` feature for now (with expectation of being marked as stable by 1.0 release).
2015-04-14RebasedNick Cameron-1/+1
2015-04-13pluralize doc comment verbs and add missing periodsAndrew Paseltiner-113/+113
2015-04-13Auto merge of #24323 - rprichard:panic-line-type, r=alexcrichtonbors-4/+4
There are syntax extensions that call `std::rt::begin_unwind` passing it a `usize`. I updated the syntax extension to instead pass `u32`, but for bootstrapping reasons, I needed to create a `#[cfg(stage0)]` version of `std::rt::begin_unwind` and therefore also `panic!`.
2015-04-12Destabilize format_args! internals.Ryan Prichard-29/+36
Arguments, Formatters, and the various format traits remain stable. The format_args! macro uses #[allow_internal_unstable] to allow it access to the unstable things in core::fmt. Destabilized things include a "v1" in their name: * core::fmt::rt * core::fmt::rt::v1 (the module and all contents) * core::fmt::ArgumentV1 * core::fmt::ArgumentV1::new * core::fmt::ArgumentV1::from_usize * core::fmt::Arguments::new_v1 * core::fmt::Arguments::new_v1_formatted The unstable message was copied from that of std::io::_print.
2015-04-12Make Debug include the - in -0.0Robin Kruppe-114/+52
2015-04-13Rollup merge of #24347 - xamgore:master, r=huonwManish Goregaokar-2/+2
Docs meant that ParseIntError is returned though the function returns ParseFloatError.
2015-04-12mod.rs documentary fixIgor Strebezhev-2/+2
Docs meant that Option is returned though the function returns Result.
2015-04-11Simplify iterator logic for FuseCorey Farwell-14/+6