rust/src/libcore
bors 1a44875af9 auto merge of #19176 : aturon/rust/stab-iter, r=alexcrichton
This is an initial pass at stabilizing the `iter` module. The module is
fairly large, but is also pretty polished, so most of the stabilization
leaves things as they are.

Some changes:

* Due to the new object safety rules, various traits needs to be split
  into object-safe traits and extension traits. This includes `Iterator`
  itself. While splitting up the traits adds some complexity, it will
  also increase flexbility: once we have automatic impls of `Trait` for
  trait objects over `Trait`, then things like the iterator adapters
  will all work with trait objects.

* Iterator adapters that use up the entire iterator now take it by
  value, which makes the semantics more clear and helps catch bugs. Due
  to the splitting of Iterator, this does not affect trait objects. If
  the underlying iterator is still desired for some reason, `by_ref` can
  be used. (Note: this change had no fallout in the Rust distro except
  for the useless mut lint.)

* In general, extension traits new and old are following an [in-progress
  convention](rust-lang/rfcs#445). As such, they
  are marked `unstable`.

* As usual, anything involving closures is `unstable` pending unboxed
  closures.

* A few of the more esoteric/underdeveloped iterator forms (like
  `RandomAccessIterator` and `MutableDoubleEndedIterator`, along with
  various unfolds) are left experimental for now.

* The `order` submodule is left `experimental` because it will hopefully
  be replaced by generalized comparison traits.

* "Leaf" iterators (like `Repeat` and `Counter`) are uniformly
  constructed by free fns at the module level. That's because the types
  are not otherwise of any significance (if we had `impl Trait`, you
  wouldn't want to define a type at all).

Closes #17701

Due to renamings and splitting of traits, this is a:

[breaking-change]
2014-11-26 17:42:07 +00:00
..
fmt Fallout from stabilization 2014-11-25 17:41:54 -08:00
num Fallout from stabilization 2014-11-25 17:41:54 -08:00
tuple Update code with new lint names 2014-10-28 08:54:21 -07:00
any.rs auto merge of #19223 : reem/rust/any-typeid-unstable, r=aturon 2014-11-24 02:56:35 +00:00
array.rs Add Show and Clone trait to arrays 2014-11-14 12:37:59 +01:00
atomic.rs Document almost all of atomics. 2014-11-19 12:53:23 -05:00
bool.rs std: Stabilize unit, bool, ty, tuple, arc, any 2014-07-26 13:12:20 -07:00
borrow.rs Deprecate MaybeOwned[Vector] in favor of Cow 2014-11-25 11:22:23 -05:00
cell.rs Rename unwrap functions to into_inner 2014-11-23 15:26:53 -08:00
char.rs core: Convert a 'failure' to 'panic' in docs 2014-11-21 13:18:08 -08:00
clone.rs DSTify impl Clone for &T 2014-11-17 14:35:27 -05:00
cmp.rs libcore: DSTify ops traits, Equiv 2014-11-20 00:05:00 -08:00
default.rs Switch to purely namespaced enums 2014-11-17 07:35:51 -08:00
finally.rs Fix fallout from coercion removal 2014-11-17 22:41:33 +13:00
intrinsics.rs Fix fallout from coercion removal 2014-11-17 22:41:33 +13:00
iter.rs libs: stabilize iter module 2014-11-25 17:41:25 -08:00
kinds.rs Implement more basic traits for the marker types. 2014-11-17 09:25:49 +11:00
lib.rs libcore: add borrow module 2014-11-17 11:26:30 -08:00
macros.rs std: Stabilize std::fmt 2014-11-18 21:16:22 -08:00
mem.rs Fixed a few typos in libcore 2014-11-16 16:51:22 -08:00
ops.rs libcore: DSTify ops traits, Equiv 2014-11-20 00:05:00 -08:00
option.rs Fallout from stabilization 2014-11-25 17:41:54 -08:00
panicking.rs Register snapshots. 2014-11-05 12:55:58 +02:00
prelude.rs Fallout from stabilization 2014-11-25 17:41:54 -08:00
ptr.rs Rename fail! to panic! 2014-10-29 11:43:07 -04:00
raw.rs rollup merge of #18398 : aturon/lint-conventions-2 2014-10-30 17:37:22 -07:00
result.rs Fallout from stabilization 2014-11-25 17:41:54 -08:00
simd.rs Update code with new lint names 2014-10-28 08:54:21 -07:00
slice.rs Fallout from stabilization 2014-11-25 17:41:54 -08:00
str.rs Fallout from stabilization 2014-11-25 17:41:54 -08:00
ty.rs std: Stabilize unit, bool, ty, tuple, arc, any 2014-07-26 13:12:20 -07:00