Commit Graph

41202 Commits

Author SHA1 Message Date
Manish Goregaokar
46f3bdf5ab Rollup merge of #24274 - steveklabnik:fix_pow_docs, r=nikomatsakis
This is very confusing now that these are inherent methods.
2015-04-11 19:04:51 +05:30
Manish Goregaokar
b6cb73b534 Rollup merge of #24259 - lstat:needstest, r=alexcrichton
Closes #20772
Closes #20939
Closes #21950
Closes #22034
2015-04-11 19:04:43 +05:30
Manish Goregaokar
dbbedb5a8b Rollup merge of #24253 - steveklabnik:doc_primitive_types, r=alexcrichton
A brief introduction to each type, with pointers to the primitive pages
for more info.
2015-04-11 19:04:37 +05:30
Manish Goregaokar
0f1723b2b7 Rollup merge of #24247 - steveklabnik:update_variable_bindings, r=huonw
keeping on with the edits
2015-04-11 19:04:30 +05:30
Manish Goregaokar
83093a2c98 Rollup merge of #24245 - nikomatsakis:issue-24241-coherence-failure, r=pnkfelix
Don't use skolemized parameters but rather fresh variables in coherence. Skolemized parameters wind up preventing unification. Surprised we had no test for this! Fixes #24241.

r? @pnkfelix
2015-04-11 19:04:22 +05:30
Manish Goregaokar
8c20c20ef4 Rollup merge of #24244 - steveklabnik:more_editing, r=steveklabnik
Fill out blank section headers. Copy edit the entire first section.
2015-04-11 19:04:15 +05:30
Manish Goregaokar
c34077539e Rollup merge of #24243 - frewsxcv:patch-13, r=steveklabnik 2015-04-11 19:04:08 +05:30
Manish Goregaokar
5bbe386a5c Rollup merge of #24242 - nikomatsakis:escaping-closure-error-message, r=brson
Example showing sample inputs, old message, new message:

https://gist.github.com/nikomatsakis/11126784ac678b7eb6ba

Also adds infrastructure for reporting suggestions \"in situ\" and does some (minor) cleanups to `CodeMap`.

r? @brson
2015-04-11 19:04:03 +05:30
Manish Goregaokar
b3c9331c25 Rollup merge of #24240 - apasel422:patch-1, r=aturon 2015-04-11 19:03:56 +05:30
Manish Goregaokar
55610d64d1 Rollup merge of #24239 - steveklabnik:editing_pass, r=steveklabnik
Now that the new TOC has landed, I've started doing an editing pass to get the old content into the right shape. I felt this introduction was significant enough to send as its own PR, though, as it's the introduction.

It's possible that we may just want to replace 'the intro' with this directly, but this PR doesn't do that.
2015-04-11 19:03:50 +05:30
Manish Goregaokar
f99341a8e0 Rollup merge of #24236 - aturon:issue-19097, r=alexcrichton
Closes #19097
2015-04-11 19:03:43 +05:30
Manish Goregaokar
f5d6cae3fc Rollup merge of #24234 - thiagooak:academic-research, r=steveklabnik
#24004

Something like this?
2015-04-11 19:03:36 +05:30
Manish Goregaokar
c4a7d9b15c Rollup merge of #24121 - steveklabnik:gh24107, r=steveklabnik 2015-04-11 19:03:29 +05:30
Manish Goregaokar
719ad518ff Rollup merge of #24285 - brson:rustup, r=alexcrichton
Now lives at https://github.com/rust-lang/rustup

r? @alexcrichton
2015-04-11 19:03:20 +05:30
Manish Goregaokar
872de9c71f Rollup merge of #24269 - benashford:formatting-fix, r=alexcrichton
This fixes the bug described in issue #23150.  This affected formatting any floating point number into a string in a formatting pattern that: a) required rounding up, and b) required an extra digit on the front.

So `format!(\"{:.0}\", 9.9)` would fail, but `format!(\"{:.0}\", 8.9)` would succeed.  This was due to a negative integer being cast to a `usize` resulting in an 'arithmetic operation overflowed' panic.

The fix was to change the order of operations so that the number is zero before casting.
2015-04-11 19:03:13 +05:30
Manish Goregaokar
1737957e19 Rollup merge of #24268 - pnkfelix:regression-tests, r=alexcrichton
A pair of regression tests for issues that seem to have been fixed since they were originally filed.
2015-04-11 19:03:04 +05:30
Tim Cuthbertson
10073c23c6 Reapply rust-specific changes to libbacktrace
This includes the changes from commits:

 - cd8f31759f
 - fcb30a0b67
2015-04-11 22:30:17 +10:00
Tim Cuthbertson
0369efa75b Update libbacktrace to r220112 (from GCC SVN) 2015-04-11 22:14:30 +10:00
bors
acb3e5136c Auto merge of #24268 - pnkfelix:regression-tests, r=alexcrichton
A pair of regression tests for issues that seem to have been fixed since they were originally filed.
2015-04-11 11:06:14 +00:00
Ryan Prichard
ef25b7d538 Change the rt::unwind line argument type from usize to u32. 2015-04-11 02:46:57 -07:00
bors
0be4e0ec50 Auto merge of #24155 - chris-chambers:stmt_macros, r=sfackler
Statement macros are now treated somewhat like item macros, in that a statement macro can now expand into a series of statements, rather than just a single statement.

This allows statement macros to be nested inside other kinds of macros and expand properly, where previously the expansion would only work when no nesting was present.

See:
- `src/test/run-pass/macro-stmt_macro_in_expr_macro.rs`
- `src/test/run-pass/macro-nested_stmt_macro.rs`

This changes the interface of the MacResult trait.  make_stmt has become make_stmts and now returns a vector, rather than a single item.  Plugin writers who were implementing MacResult will have breakage, as well as anyone using MacEager::stmt.

See:
- `src/libsyntax/ext/base.rs`

This also causes a minor difference in behavior to the diagnostics produced by certain malformed macros.

See:
- `src/test/compile-fail/macro-incomplete-parse.rs`
2015-04-11 08:07:34 +00:00
Luke Gallagher
117512348b Add tests for #16602
Closes #16602
2015-04-11 17:13:24 +10:00
Christopher Chambers
77627ea8dd Moves expand_stmt's bt_pop so that it balances correctly. 2015-04-11 00:59:00 -05:00
bors
3a8275397a Auto merge of #24254 - aturon:join-handle-debug, r=alexcrichton
Make `Box<Any + Send>` implement `Debug`.

Fixes #21291
2015-04-11 05:57:55 +00:00
Christopher Chambers
22eb3193a6 Simplifications to statement macro handling.
SmallVector::pop no longer worries about converting a Many repr downward
to One or Zero.

expand_stmt makes use of `if let` for style purposes.
2015-04-10 23:42:40 -05:00
Christopher Chambers
fae29e497c Eliminates a pointless is_empty test. 2015-04-10 22:20:01 -05:00
Christopher Chambers
b16cfacbcc Improves semicolon expansion efficiency, corrects bt_pop placement.
Implements pop() on SmallVector, and uses it to expand the final semicolon
in a statement macro expansion more efficiently.

Corrects the placement of the call to fld.cx.bt_pop().  It must run
unconditionally to reverse the corresponding push.
2015-04-10 21:50:23 -05:00
bors
c87ec1edb1 Auto merge of #24186 - richo:pad-pointers, r=alexcrichton
This pads out the printing of pointers to their native width.

Extracted from and rebased on top of #24144
2015-04-11 01:59:18 +00:00
Richo Healey
7a1d726696 mk: Add a printer helper to the make setup
Also add docs because not being able to discover these things is the
pits.
2015-04-10 17:10:03 -07:00
bors
93f7fe32d3 Auto merge of #24270 - pnkfelix:use-disr-val-for-derive-ord, r=brson
Use `discriminant_value` intrinsic for `derive(PartialOrd)`

[breaking-change]

This is a [breaking-change] because it can change the result of comparison operators when enum discriminants have been explicitly assigned.  Notably in a case like:
```rust
#[derive(PartialOrd)]
enum E { A = 2, B = 1}
```

Under the old deriving, `A < B` held, because `A` came before `B` in the order of declaration.  But now we use the ordering according to the provided values, and thus `A > B`.  (However, this change is very unlikely to break much, if any, code, since the orderings themselves should all remain well-defined, total, etc.)

Fix #15523
2015-04-10 23:49:24 +00:00
Alex Crichton
f329030b09 std: Stabilize the Utf8Error type
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-10 16:07:46 -07:00
Felix S. Klock II
05aaad114f Remove pretty-expanded from 2 tests; deriving(Ord) uses unstable intrinsic. 2015-04-11 00:50:59 +02:00
Tshepang Lekhonkhobe
386a144e51 book: 'x' is already taken, so use something else 2015-04-11 00:48:16 +02:00
Tibor Benke
520ee34a66 Fix some typos
Signed-off-by: Tibor Benke <ihrwein@gmail.com>
2015-04-10 22:51:05 +02:00
Steve Klabnik
f01dbf2194 More editing work on TRPL
Fill out blank section headers. Copy edit the entire first section.
2015-04-10 16:28:55 -04:00
Oak
b4c49ba212 mod.rs docs fix - for floats
Same with integers — docs meant that Option is returned though the function returns Result.
2015-04-10 23:20:40 +04:00
Oak
c7697ee86d mod.rs docs fix
Docs meant that Option is returned though the function returns Result.
2015-04-10 23:16:47 +04:00
Igor Strebezhev
9e68d236a7 Fix mistake in documentation 2015-04-10 20:32:38 +03:00
Guillaume Gomez
f1515fabb0 Add Default trait for AtomicBool, AtomicIsize and AtomicUsize 2015-04-10 19:26:06 +02:00
Felix S. Klock II
847a897fb3 fix some comments. 2015-04-10 19:13:34 +02:00
Brian Anderson
2cf7bc3e3d Bump prerelease version 2015-04-10 10:12:27 -07:00
Felix S. Klock II
47016f9ce5 Test case for 64-bit corner cases where truncation occurred before prior commit. 2015-04-10 19:11:03 +02:00
Felix S. Klock II
781fc902a4 Incorporate repr-attr into deriving(PartialOrd) to avoid truncation errors.
remove out of date fixme.
2015-04-10 19:11:00 +02:00
Brian Anderson
a0f832da52 Remove rustup.sh.
Now lives at https://github.com/rust-lang/rustup
2015-04-10 10:01:04 -07:00
Steve Klabnik
288b1c9aba Add examples for Convert 2015-04-10 12:44:20 -04:00
Andrew Paseltiner
7bf1da1283 s/Panicks/Panics/ 2015-04-10 12:42:36 -04:00
Simon Sapin
c2fa1f769d Doc: remove a "safety note" made obsolete by dropck for TypedArena
https://botbot.me/mozilla/rust-internals/2015-04-10/?msg=36316959&page=6
2015-04-10 18:30:52 +02:00
Steve Klabnik
74b5c75d74 copyediting: while loops 2015-04-10 12:26:58 -04:00
Steve Klabnik
8d35fc6303 copyediting: for loops 2015-04-10 12:26:58 -04:00
Steve Klabnik
b577beeb3a copyedits: patterns
This also puts slice patterns in nightly docs, where they belong.
2015-04-10 12:26:58 -04:00