Commit Graph

54447 Commits

Author SHA1 Message Date
Alex Crichton ab06acedd6 mk: Request -march=i686 on i686 Linux
Apparently the gcc on our dist bot is so old and/or obscure that the default
`-m32` switch doesn't think it can generate i686 code (or something like that).
The compiler-rt build system probes for the `__i686__` define in GCC to compile
for an i686 (vs i386) target, so this was failing on the bots.

This tweaks instead to pass `-march=i686` on i686-unknown-linux-gnu to C code to
ensure that we're compiling for i686 instead of i386. This should hopefully not
actually have an impact other than maybe doing some random optimization it
wasn't able to do so before. In theory this isn't making the target less
compatible as all Rust code is already compiled for i686.

Hopefully closes #34572
2016-06-30 10:25:46 -07:00
bors c2b56fb7a0 Auto merge of #34552 - Manishearth:rollup, r=Manishearth
Rollup of 11 pull requests

- Successful merges: #34355, #34446, #34459, #34460, #34467, #34495, #34497, #34499, #34513, #34536, #34542
- Failed merges:
2016-06-29 18:44:27 -07:00
bors 5dd1001253 Auto merge of #34553 - alexcrichton:fix-nightlies, r=brson
configure: Fix cross-compiling LLVM for realz

Actually got it working this time, and it was again just a problem specifying
the llvm-tblgen binary. We need to point it at the $CFG_BUILD target's tblgen
and then we also needed to correct the path a bit.
2016-06-29 16:02:34 -07:00
Alex Crichton 213f1638d9 configure: Fix cross-compiling LLVM for realz
Actually got it working this time, and it was again just a problem specifying
the llvm-tblgen binary. We need to point it at the $CFG_BUILD target's tblgen
and then we also needed to correct the path a bit.
2016-06-29 09:05:18 -07:00
Manish Goregaokar 8e2598c3d2 Rollup merge of #34542 - jseyfried:fix_recursive_modules, r=nrc
Fix non-termination on recursive module re-exports in extern crates

Fixes #33776.
r? @nrc
2016-06-29 21:21:24 +05:30
Manish Goregaokar cc15c211c5 Rollup merge of #34536 - ollie27:rustdoc_module_impls, r=alexcrichton
rustdoc: Fix empty Implementations section on some module pages

These are caused by `DefaultImpl`s.

For example [`core::marker`](https://doc.rust-lang.org/nightly/core/marker/#impls).
2016-06-29 21:21:23 +05:30
Manish Goregaokar b393c7e0d2 Rollup merge of #34513 - ollie27:rustdoc_stripped, r=alexcrichton
rustdoc: Fix a few stripping issues

We need to recurse into stripped modules to strip things like impl methods
but when doing so we must not add any items to the `retained` set.

For example this removes [`core::num::ParseFloatError::__description`](https://doc.rust-lang.org/nightly/core/num/struct.ParseFloatError.html#method.__description) and [`impl Clone for ThreadRng`](https://doc.rust-lang.org/nightly/std/clone/trait.Clone.html).
2016-06-29 21:21:23 +05:30
Manish Goregaokar 5bd3ef81c6 Rollup merge of #34499 - michaelwoerister:lldb-blacklist, r=alexcrichton
Disable debuginfo tests for a given blacklist of LLDB versions

Anyone having trouble with most LLDB tests failing on OSX, please report your LLDB version here so I can add it to the blacklist.

Blacklisted versions so far:
* lldb-350.*

cc @rust-lang/tools
cc @tedhorst @indutny @jonathandturner (people from the original bug report)

Fixes #32520.
2016-06-29 21:21:23 +05:30
Manish Goregaokar 2e893ea6de Rollup merge of #34497 - oli-obk:double_negation, r=eddyb
Revert "skip double negation in const eval"

This reverts commit 735c018974.

fixes #34395

The original commit was based on a mis-understanding of the overflowing literal lint.

This needs to be ported to beta.

r? @eddyb
2016-06-29 21:21:22 +05:30
Manish Goregaokar 8886818a9a Rollup merge of #34495 - jseyfried:only_ident_macro_invocations, r=eddyb
Forbid type parameters and global paths in macro invocations

Fixes #28558.
This is a [breaking-change]. For example, the following would break:
```rust
macro_rules! m { () => { () } }
fn main() {
    m::<T>!(); // Type parameters are no longer allowed in macro invocations
    ::m!(); // Global paths are no longer allowed in macro invocations
}
```
Any breakage can be fixed by removing the type parameters or the leading `::` (respectively).

r? @eddyb
2016-06-29 21:21:22 +05:30
Manish Goregaokar 2a0c2c3b3a Rollup merge of #34467 - GuillaumeGomez:err-codes, r=brson
Add new error codes and improve some explanations

r? @brson

cc @steveklabnik
cc @jonathandturner
2016-06-29 21:21:22 +05:30
Manish Goregaokar d11ac236b1 Rollup merge of #34460 - dsprenkels:issue-33455, r=alexcrichton
Add regression test for #33455

Closes #33455.
2016-06-29 21:21:21 +05:30
Manish Goregaokar fd45e6e912 Rollup merge of #34459 - jseyfried:expansion_cleanup, r=nrc
Miscellaneous macro expansion cleanup and groundwork

r? @nrc
2016-06-29 21:21:21 +05:30
Manish Goregaokar 470c5191f5 Rollup merge of #34446 - jseyfried:refactor_decorators, r=nrc
Treat `MultiDecorator`s as a special case of `MultiModifier`s

This deals with #32950 by using @durka's [option 1](https://github.com/rust-lang/rust/pull/33769#issuecomment-221774136).
r? @nrc
2016-06-29 21:21:21 +05:30
Manish Goregaokar f74d0fb568 Rollup merge of #34355 - jseyfried:paren_expression_ids_nonunique, r=nrc
Give `ast::ExprKind::Paren` no-op expressions the same ids as their children.

Having `ast::ExprKind::Paren` expressions share ids with their children
 - reduces the number of unused `NodeId`s in the hir map and
 - guarantees that `tcx.map.expect_expr(ast_expr.id)` is the hir corresponding to `ast_expr`.

This fixes the bug from #34327, which was introduced in #33296 when I assumed the above guarantee.

r? @nrc
2016-06-29 21:21:21 +05:30
Jeffrey Seyfried 8557a2e18c Give `ast::ExprKind::Paren` no-op expressions the same node ids as their children. 2016-06-29 11:06:28 +00:00
Jeffrey Seyfried a9d25f8b59 Refactor away `parser.commit_stmt_expecting()` 2016-06-29 06:40:05 +00:00
Jeffrey Seyfried a595ffaac5 Treat `MultiDecorator`s as a special case of `MultiModifier`s 2016-06-29 01:25:46 +00:00
Jeffrey Seyfried 66ef652559 Disallow `derive` on items with type macros 2016-06-29 01:25:36 +00:00
Jeffrey Seyfried 9ffe1c9fba Add regression test 2016-06-29 00:27:18 +00:00
Jeffrey Seyfried 232783c914 Fix infinite loop on recursive module exports in an extern crate 2016-06-28 23:03:56 +00:00
Oliver Middleton f05da01dbe rustdoc: Fix empty Implementations section on some module pages
These are caused by `DefaultImpl`s.
2016-06-28 22:53:50 +01:00
bors 366de839ae Auto merge of #34519 - alexcrichton:fix-nightlies, r=brson
Try to fix the nightlies

They look to be failing right after the CMake PR landed. I've diagnosed and confirmed the first issue fixed, the second is a bit of a shot in the dark to see if it fixes things.
2016-06-28 11:52:36 -07:00
bors 59152a45af Auto merge of #34525 - GuillaumeGomez:rollup, r=GuillaumeGomez
Rollup of 13 pull requests

- Successful merges: #34080, #34287, #34328, #34406, #34415, #34442, #34462, #34471, #34475, #34479, #34517, #34518, #34524
- Failed merges: #33951
2016-06-28 07:48:56 -07:00
Guillaume Gomez dd56a6ad08 Rollup merge of #34524 - frewsxcv:std-io-sink, r=GuillaumeGomez
Add doc example for `std::io::sink`.

None
2016-06-28 16:05:16 +02:00
Guillaume Gomez dcc8fa5270 Rollup merge of #34518 - frewsxcv:io-repeat, r=GuillaumeGomez
Add doc example for `std::io::repeat`.

None
2016-06-28 16:05:16 +02:00
Guillaume Gomez f47fcc738b Rollup merge of #34517 - frewsxcv:empty, r=GuillaumeGomez
Minor rewrite of `std::io::empty` doc example.

None
2016-06-28 16:05:16 +02:00
Guillaume Gomez 890e3a7a1a Rollup merge of #34479 - ollie27:rustdoc_renamed_reexport_list, r=GuillaumeGomez
rustdoc: Fix inlined renamed reexports in import lists

Fixes #34473
2016-06-28 16:05:15 +02:00
Guillaume Gomez f8453a1d17 Rollup merge of #34475 - frewsxcv:path-component, r=GuillaumeGomez
Expand `std::path::Component` documentation.

Indicate how it gets created and add an example.
2016-06-28 16:05:15 +02:00
Guillaume Gomez b34f6e7245 Rollup merge of #34471 - GuillaumeGomez:fix_expl, r=steveklabnik
Fix E0269 error explanation

r? @steveklabnik
2016-06-28 16:05:15 +02:00
Guillaume Gomez b765edf440 Rollup merge of #34462 - dns2utf8:leading_zeros, r=GuillaumeGomez
Add example with leading zeros

I was searching for this format very long. So I added an example to the prominent section.

I was thinking of putting the keyword leading in the corresponding section as well, what do you think?

r? @steveklabnik
2016-06-28 16:05:15 +02:00
Guillaume Gomez 86e4a034af Rollup merge of #34442 - tatsuya6502:doc-book-ownership, r=steveklabnik
[doc] Fix links in Ownership section of the book

- Add a missing link definition for `[i32]`.
- Like `[stack]` link is pointing to `...#the-stack`, append `#the-heap` to `[heap]` link.
2016-06-28 16:05:14 +02:00
Guillaume Gomez adc70bdc90 Rollup merge of #34415 - ollie27:docs_float, r=steveklabnik
Use the correct types in float examples

r? @steveklabnik
2016-06-28 16:05:14 +02:00
Guillaume Gomez 5d6b41f3bc Rollup merge of #34406 - frewsxcv:sleep-ex, r=alexcrichton
Add example for `std:🧵:sleep`.

None
2016-06-28 16:05:14 +02:00
Guillaume Gomez 47ef866f43 Rollup merge of #34328 - wuranbo:patch-1, r=steveklabnik
Traits where syntax's extra usage example more clearly

r? @steveklabnik
2016-06-28 16:05:13 +02:00
Guillaume Gomez be1c2b9c8c Rollup merge of #34287 - durka:patch-26, r=steveklabnik
update reference for #29734
2016-06-28 16:05:13 +02:00
Guillaume Gomez cea2438834 Rollup merge of #34080 - royalstream:royalstream-book-june4, r=steveklabnik
Syntax coloring and more compact diagram

Two cosmetic improvements:
- New content was added a few days ago to the **Closures** chapter but it was missing rust's syntax coloring.
- Also, in the **Crates and Modules** chapter, a diagram was improved to be more symmetric and to take less space.
2016-06-28 16:05:12 +02:00
Corey Farwell 325e09e952 Add doc example for `std::io::sink`. 2016-06-28 08:22:44 -04:00
Jeffrey Seyfried e58963d3e4 groundwork: create the `Resolver` earlier in phase 2 2016-06-28 05:28:27 +00:00
Jeffrey Seyfried ec0c150152 groundwork: refactor the interface that `resolve` exposes to `driver` 2016-06-28 05:28:26 +00:00
Jeffrey Seyfried 36a4eb9940 cleanup: refactor away `ast::NodeIdAssigner` 2016-06-28 05:28:25 +00:00
Jeffrey Seyfried 4a13bcb4fb groundwork: use `resolve_identifier` instead of `resolve_path` to classify ident patterns 2016-06-28 05:28:23 +00:00
Jeffrey Seyfried 2dc15f2b96 cleanup: use `DummyResult` to implement `MacroGenerable::dummy` 2016-06-28 05:28:22 +00:00
Jeffrey Seyfried b968ee3656 cleanup: don't count attributes on an item in a statement position as on the statement 2016-06-28 05:28:20 +00:00
Corey Farwell a350ca62cd Minor rewrite of `std::io::empty` doc example.
Remove unnecessary hidden `foo` function.
Demonstrate this emptiness of the resulting string.
Combine imports.
2016-06-27 22:28:28 -04:00
Alex Crichton 3fd411e017 mk: Make some LLVM building support more robust
* Implement the clean-llvm target for those cases where makefiles are being used
* Have all cross-compiled LLVMs depend on the **host** LLVM as they'll require
  the llvm-tablegen executable from there
2016-06-27 18:59:55 -07:00
Alex Crichton ea1818f1ca rustbuild: Update how compiler-rt is called
Looks like compiler-rt has been tweaked slightly during the last update,
propagate these changes to rustbuild as well.
2016-06-27 18:53:17 -07:00
Corey Farwell 18b094bdbd Add doc example for `std::io::repeat`. 2016-06-27 21:23:53 -04:00
bors ea0dc92972 Auto merge of #34424 - jseyfried:breaking_batch, r=Manishearth
Batch up libsyntax breaking changes

Batch of the following syntax-[breaking-change] changes:
 - #34213: Add a variant `Macro` to `TraitItemKind`
 - #34368: Merge the variant `QPath` of `PatKind` into the variant `PatKind::Path`
 - #34385: Move `syntax::ast::TokenTree` into a new module `syntax::tokenstream`
 - #33943:
  - Remove the type parameter from `visit::Visitor`
  - Remove `attr::WithAttrs` -- use `attr::HasAttrs` instead.
  - Change `fold_tt`/`fold_tts` to take token trees by value and avoid wrapping token trees in `Rc`.
  - Remove the field `ctxt` of `ast::Mac_`
  - Remove inherent method `attrs()` of types -- use the method `attrs` of `HasAttrs` instead.
 - #34316:
  - Remove `ast::Decl`/`ast::DeclKind` and add variants `Local` and `Item` to `StmtKind`.
  - Move the node id for statements from the `StmtKind` variants to a field of `Stmt` (making `Stmt` a struct instead of an alias for `Spanned<StmtKind>`)
  - Rename `ast::ExprKind::Again` to `Continue`.
 - #34339: Generalize and abstract `ThinAttributes` to `ThinVec<Attribute>`
  - Use `.into()` in convert between `Vec<Attribute>` and `ThinVec<Attribute>`
  - Use autoderef instead of `.as_attr_slice()`
 - #34436: Remove the optional expression from `ast::Block` and instead use a `StmtKind::Expr` at the end of the statement list.
 - #34403: Move errors into a separate crate (unlikely to cause breakage)
2016-06-27 16:42:03 -07:00
Jeffrey Seyfried 360dcae419 Update `src/rustc/Cargo.lock` 2016-06-27 23:40:04 +00:00