Commits on Aug 3, 2014
  1. auto merge of #16155 : huonw/rust/Ordering-reverse, r=alexcrichton

    This flips the comparison and is designed to be used when sorting etc.
    bors committed Aug 3, 2014
  2. auto merge of #16194 : omasanori/rust/gitignore, r=alexcrichton

    I also sorted lines in .gitignore. The file might include some obsoleted lines but I left.
    bors committed Aug 3, 2014
  3. auto merge of #16191 : DaGenix/rust/fix-aligned-access, r=alexcrichton

    When I originally wrote the read_u32v_be() and write_u32_be() functions, I didn't consider memory alignment requirements of various architectures. Unfortunately, the current implementations may result in unaligned reads and writes. This doesn't impact x86 / x86_64, but it can cause a compiler crash on ARM. This pull requests rewrites those functions to make sure that all memory access is always correctly aligned.
    This fix is a little bit academic - due to the way that LLVM aligns the structures that are passed as arguments to these functions, I believe that the end result is that all memory access happens to be aligned anyway. However, there is nothing in that code that actually enforces that, at least not explicitly. The new implementations are definitely slower than the existing ones. However, I don't believe that these functions are all that significant when looking at the overall performance of the compiler. I think getting rid of some unsafe code and removing a potential portability landmine justifies a very slight decrease in raw performance.
    bors committed Aug 3, 2014
  4. core: add a reverse method to Ordering.

    This flips the comparison and is designed to be used when sorting etc.
    huonw committed Aug 1, 2014
Commits on Aug 2, 2014
  1. auto merge of #16186 : steveklabnik/rust/guide_cargo_new, r=alexcrichton

    Two commits here: one to add `cargo new` to the guide, and a second to mention the lockfile that Cargo now generates.
    bors committed Aug 2, 2014
  2. auto merge of #16169 : Gankro/rust/simple-docs, r=cmr

    <strike>Adds a simple/detailed toggle to api doc pages.
    Detailed mode is the current behaviour, simple mode hides all doccomment details leaving only signatures for quick browsing.
    Adds [expand all] and [collapse all] "links" to all api doc pages. All doccomments are collapsed, leaving only signatures for quick browsing.
    In addition, clicking on a <strike>function name</strike> function's [toggle details] link now toggles the visibility of the associated doccomment.
    # [Live Build Here](
    This is something that's been bothering me, and I've seen some people mention in IRC before. The docs are *great* if you want a full in-depth look at an API, but *awful* if you want to scan them. This provides the ability to toggle complexity freely. Interacts perfectly well with noscript, since the static page is effectively unchanged. Collapsing is just hiding divs with css.
    I'm not much of a designer, so design input welcome on the actual UX for toggling.
    The actual javascript is *a bit* brittle to layout changes, but it always will be without adding lots of extra junk to the actual markup, which didn't seem worth it.
    bors committed Aug 2, 2014
  3. fix underflow in vec swap_remove

    fixes #16200
    Gankro committed Aug 2, 2014
  4. Use globs to ignore target directories.

    Signed-off-by: OGINO Masanori <>
    omasanori committed Aug 2, 2014
  5. Sort .gitignore.

    Signed-off-by: OGINO Masanori <>
    omasanori committed Aug 2, 2014
  6. Add hide/show detail toggles to rustdoc

    All doccomments are now collapsable via a nearby [-] button
    Adds [collapse all] and [expand all] buttons to the top of all api pages
    Tweaks some layout to accomadate this
    Gankro committed Jul 31, 2014
  7. Remove unused tuple struct

    cakebaker committed Aug 2, 2014
  8. auto merge of #16177 : nham/rust/collections_15294_eq_ord, r=alexcric…

    This implements:
     - Eq and Ord for DList, RingBuf, TreeMap and TreeSet
     - FromIterator and Extendable for BitvSet
    cc #15294
    bors committed Aug 2, 2014
  9. auto merge of #16175 : EduardoBautista/rust/fix-guessing-game-appeari…

    …ng-early, r=steveklabnik
    Solves: rust-lang#16162
    bors committed Aug 2, 2014
  10. auto merge of #16165 : tinaun/rust/newcss, r=alexcrichton

    remove unneeded `pre.rust a' selector
    move transform into `.test-arrow`
    fixes #16138
    bors committed Aug 2, 2014
  11. auto merge of #16163 : anguslees/rust/strptime-str, r=alexcrichton

    Also modernise a few constructs in match_strs().
    bors committed Aug 2, 2014
  12. Rewrite read_u32v_be() and write_u32_be() to make sure that all memor…

    …y access is properly aligned
    Palmer Cox committed Aug 2, 2014
  13. auto merge of #16160 : EduardoBautista/rust/use-bang-at-end-of-hello-…

    …world, r=alexcrichton
    Further into the guide "Hello, world!" is used instead of "Hello, world".
    bors committed Aug 2, 2014
  14. Add note about Cargo.lock

    steveklabnik committed Aug 2, 2014
  15. Use cargo new.

    Now that this feature exists, we should use it.
    Fixes #16078
    steveklabnik committed Aug 2, 2014
  16. auto merge of #16128 : steveklabnik/rust/speed_faq, r=brson

    Fixes #11174.
    I'm open to revising this text, but I figured it gets across the basics.
    bors committed Aug 2, 2014
  17. auto merge of #16119 : steveklabnik/rust/guide_pointers, r=brson

    This is the next section of the guide, and it's on pointers. It's not done yet, as I need to write the section on ownership and borrowing, but I figured I'd share the rest now, to get feedback on the rest of it while I take some time to get that right.
    bors committed Aug 2, 2014
Commits on Aug 1, 2014
  1. mk: Add missing colon

    brson committed Aug 1, 2014
  2. Fix misspelled comments.

    jbcrail committed Aug 1, 2014
  3. auto merge of #15995 : Ryman/rust/sync_spsc_peek, r=alexcrichton

    The current spsc implementation doesn't enforce single-producer
    single-consumer usage and also allows unsafe memory use through
    peek & pop.
    For safer usage, `new` now returns a pair of owned objects which
    only allow consumer or producer behaviors through an `Arc`.
    Through restricting the mutability of the receiver to `mut` the
    peek and pop behavior becomes safe again, with the compiler
    complaining about usage which could lead to problems.
    To fix code broken from this, update:
    Queue::new(x) -> unsafe { Queue::unchecked_new(x) }
    For an example of broken behavior, check the added test which uses the unchecked constructor.
    bors committed Aug 1, 2014