about summary refs log tree commit diff
AgeCommit message (Collapse)AuthorLines
2017-08-14Rollup merge of #43868 - lukaramu:issue-43866, r=steveklabnikCorey Farwell-0/+2
Add missing newline in Deref docs to fix rendering Fixes #43866. (Verified locally.) r? @steveklabnik
2017-08-14Rollup merge of #43862 - QuietMisdreavus:get-in-line-autohide, r=GuillaumeGomezCorey Farwell-1/+1
rustdoc: put auto-hidden docblock labels in line with the toggle before: ![image](https://user-images.githubusercontent.com/5217170/29279951-0cf21d86-80df-11e7-86d5-bfd76c5df429.png) after: ![image](https://user-images.githubusercontent.com/5217170/29279962-18479ce2-80df-11e7-952a-d22cb03965e5.png) (images taken from `std::heap::AllocErr`)
2017-08-14Rollup merge of #43848 - frewsxcv:frewsxcv-stack-size, r=QuietMisdreavusCorey Farwell-10/+45
Rewrite/reorganize docs for stack size/thread names for spawned threads. * Moves docs about stack size and thread naming from `Builder` to the `std::thread` module * Adds more links to the new module-level documentation * Mentions the 2 MiB stack size default, but indicate it's subject to change Fixes https://github.com/rust-lang/rust/issues/43805.
2017-08-14Rollup merge of #43846 - frewsxcv:frewsxcv-mailmap, r=Mark-SimulacrumCorey Farwell-1/+0
Remove my mailmap entry. I no longer want this mailmap entry for myself.
2017-08-14Rollup merge of #43790 - steveklabnik:rustdoc-passes, r=QuietMisdreavusCorey Farwell-1/+84
Write the "passes" chapter of the rustdoc book cc #42322 r? @rust-lang/docs
2017-08-14Rollup merge of #43756 - sfackler:instant-nondecreasing, r=alexcrichtonCorey Farwell-2/+2
Instant is monotonically nondecreasing We don't want to guarantee that `Instant::now() != Instant::now()` is always true since that depends on the speed of the processor and the resolution of the clock.
2017-08-14Add missing newline in Deref docs to fix renderinglukaramu-0/+2
Fixes #43866.
2017-08-14Auto merge of #43826 - kennytm:fix-43796-mis-calculated-spans, r=petrochenkovbors-123/+33
Fix "Mis-calculated spans" errors from `-Z save-analysis` + refactoring Removed the path span extraction methods from `SpanUtils`: * spans_with_brackets * spans_for_path_segments * spans_for_ty_params Use the `span` fields in `PathSegment` and `TyParam` instead. (Note that since it processes `ast::Path` not a qualified path (`hir::QPath` / `ast::QSelf`), UFCS path will be flattened: `<Foo as a::b::c::Trait>::D::E::F::g` will be seen as `a::b::c::Trait::D::E::F::g`.) Fix #43796. Close #41478. r? @nrc
2017-08-14Write the "passes" chapter of the rustdoc booksteveklabnik-1/+84
cc #42322
2017-08-14Indicate which stack size option has precedence.Corey Farwell-1/+1
2017-08-14Auto merge of #43574 - notriddle:master, r=sfacklerbors-0/+71
Implement `RefCell::replace` and `RefCell::swap` Tracking issue: #43570
2017-08-14rustdoc: put auto-hidden docblock labels in line with the toggleQuietMisdreavus-1/+1
2017-08-14Auto merge of #43740 - michaelwoerister:local-id-in-typecktables, r=arielb1bors-544/+1222
Use hir::ItemLocalId as keys in TypeckTables. This PR makes `TypeckTables` use `ItemLocalId` instead of `NodeId` as key. This is needed for incremental compilation -- for stable hashing and for being able to persist and reload these tables. The PR implements the most important part of https://github.com/rust-lang/rust/issues/40303. Some notes on the implementation: * The PR adds the `HirId` to HIR nodes where needed (`Expr`, `Local`, `Block`, `Pat`) which obviates the need to store a `NodeId -> HirId` mapping in crate metadata. Thanks @eddyb for the suggestion! In the future the `HirId` should completely replace the `NodeId` in HIR nodes. * Before something is read or stored in one of the various `TypeckTables` subtables, the entry's key is validated via the new `TypeckTables::validate_hir_id()` method. This makes sure that we are not mixing information from different items in a single table. That last part could be made a bit nicer by either (a) new-typing the table-key and making `validate_hir_id()` the only way to convert a `HirId` to the new-typed key, or (b) just encapsulate sub-table access a little better. This PR, however, contents itself with not making things significantly worse. Also, there's quite a bit of switching around between `NodeId`, `HirId`, and `DefIndex`. These conversions are cheap except for `HirId -> NodeId`, so if the valued reviewer finds such an instance in a performance critical place, please let me know. Ideally we convert more and more code from `NodeId` to `HirId` in the future so that there are no more `NodeId`s after HIR lowering anywhere. Then the amount of switching should be minimal again. r? @eddyb, maybe?
2017-08-14Fix unused variable warnings in builds disabled debug-assertions.Michael Woerister-2/+1
2017-08-14Auto merge of #43857 - michaelwoerister:fix-impl-trait-closure-vis, r=eddybbors-0/+16
Mark closures return via impl-trait as reachable. This should fix some of the open `impl trait` issues, like #40839, #43135, and #35870. r? @eddyb
2017-08-14save-analysis: Remove path span extraction methods from SpanUtilskennytm-123/+33
Use the `span` field in PathSegment and TyParam instead. Fix #43796. Close #41478.
2017-08-14Mark closures return via impl-trait as reachable.Michael Woerister-0/+16
2017-08-14Fix some merge fallout.Michael Woerister-15/+4
2017-08-14Auto merge of #43856 - sfackler:no-inline-debug, r=alexcrichtonbors-5/+0
Don't inline debug methods The inner methods aren't inlined, so this puts more pressure on LLVM for literally no benefit. Closes #43843
2017-08-14Auto merge of #43844 - arielb1:literally-nonstandard, r=eddybbors-6/+44
ast_validation: forbid "nonstandard" literal patterns Since #42886, macros can create "nonstandard" PatKind::Lit patterns, that contain path expressions instead of the usual literal expr. These can cause trouble, including ICEs. We *could* map these nonstandard patterns to PatKind::Path patterns during HIR lowering, but that would be much effort for little gain, and I think is too risky for beta. So let's just forbid them during AST validation. Fixes #43250. beta-nominating because regression. r? @eddyb
2017-08-14Auto merge of #43842 - bjorn3:no_llvm_cleanup, r=alexcrichtonbors-141/+144
Cleanup for "Support compiling rustc without LLVM (try 2)" This includes a small patch to allow running tests without llvm. Also check if you are not trying to compile a dylib. cc #42932 r? @alexcrichton
2017-08-13Don't inline debug methodsSteven Fackler-5/+0
The inner methods aren't inlined, so this puts more pressure on LLVM for literally no benefit. Closes #43843
2017-08-13Auto merge of #43836 - taleks:issue-39827, r=arielb1bors-4/+63
Fix for issue #39827 *Cause of the issue* While preparing for `trans_intrinsic_call()` invoke arguments are processed with `trans_argument()` method which excludes zero-sized types from argument list (to be more correct - all arguments for which `ArgKind` is `Ignore` are filtered out). As result `volatile_store()` intrinsic gets one argument instead of expected address and value. *How it is fixed* Modification of the `trans_argument()` method may cause side effects, therefore change was implemented in `volatile_store()` intrinsic building code itself. Now it checks function signature and if it was specialised with zero-sized type, then emits `C_nil()` instead of accessing non-existing second argument.
2017-08-13Indicate thread names get passed to the OS.Corey Farwell-4/+8
2017-08-13Auto merge of #43815 - alexcrichton:optimize-alloc, r=sfacklerbors-76/+133
Optimize allocation paths in RawVec Since the `Alloc` trait was introduced (https://github.com/rust-lang/rust/pull/42313) and it was integrated everywhere (https://github.com/rust-lang/rust/pull/42727) there's been some slowdowns and regressions that have slipped through. The intention of this PR is to try to tackle at least some of them, but they've been very difficult to quantify up to this point so it probably doesn't solve everything. This PR primarily targets the `RawVec` type, specifically the `double` function. The codegen for this function is now much closer to what it was before #42313 landed as many runtime checks have been elided.
2017-08-13Rewrite docs for stack size/thread names for spawned threads.Corey Farwell-10/+41
* Moves docs about stack size and thread naming from `Builder` to the `std::thread` module * Adds more links to the new module-level documentation * Mentions the 2 MiB stack size default, but indicate it's subject to change Fixes https://github.com/rust-lang/rust/issues/43805.
2017-08-13Fix errorbjorn3-0/+1
2017-08-13ast_validation: forbid "nonstandard" literal patternsAriel Ben-Yehuda-6/+44
Since #42886, macros can create "nonstandard" PatKind::Lit patterns, that contain path expressions instead of the usual literal expr. These can cause trouble, including ICEs. We *could* map these nonstandard patterns to PatKind::Path patterns during HIR lowering, but that would be much effort for little gain, and I think is too risky for beta. So let's just forbid them during AST validation. Fixes #43250.
2017-08-13Remove my mailmap entry.Corey Farwell-1/+0
2017-08-13Update driver.rsbjorn3-1/+1
2017-08-13Change run-make ignore messagebjorn3-1/+1
2017-08-13Change a #[cfg()] to a cfg!()bjorn3-2/+1
2017-08-13Fix tidy errorsbjorn3-7/+15
2017-08-13Remove some more cfg'sbjorn3-106/+119
2017-08-13Auto merge of #43839 - GuillaumeGomez:rollup, r=GuillaumeGomezbors-175/+268
Rollup of 8 pull requests - Successful merges: #43782, #43803, #43814, #43819, #43821, #43822, #43824, #43833 - Failed merges:
2017-08-13Addresses comments in PR #43836Alexey Tarasov-126/+16
- removes warnings introduced in changeset 0cd3587 - makes documentation more neat and grammatically correct
2017-08-13Rollup merge of #43833 - dtolnay:connect-timeout, r=sfacklerGuillaume Gomez-1/+1
Fix TcpStream::connect_timeout tracking issue number Before: https://github.com/rust-lang/rust/pull/43709 After: https://github.com/rust-lang/rust/issues/43079 r? @sfackler
2017-08-13Rollup merge of #43824 - kennytm:fix-43232-hir-stats, r=petrochenkovGuillaume Gomez-0/+5
Fix `-Z hir-stats` always panics. Fix #43232.
2017-08-13Rollup merge of #43822 - topecongiro:missing-span-let, r=petrochenkovGuillaume Gomez-1/+1
Include 'let' keyword to the span for ast::Local Currently the span for `ast::Local` does not the include the `let` keyword. This PR fixes it.
2017-08-13Rollup merge of #43821 - NilSet:redox-dns, r=alexcrichtonGuillaume Gomez-14/+12
Handle DNS label compression in more places in Redox name resolution
2017-08-13Rollup merge of #43819 - frewsxcv:frewsxcv-include, r=QuietMisdreavusGuillaume Gomez-8/+47
Improve doc examples for `include*` macros.
2017-08-13Rollup merge of #43814 - Eijebong:fix_typos2, r=petrochenkovGuillaume Gomez-82/+83
Fix some typos Follow up of #43794 If refined my script a little bit and found some more.
2017-08-13Rollup merge of #43803 - GuillaumeGomez:missing-links-doc, r=frewsxcvGuillaume Gomez-39/+64
Missing links doc r? @rust-lang/docs
2017-08-13Rollup merge of #43782 - nrc:include, r=GuillaumeGomezGuillaume Gomez-30/+55
Fix include! in doc tests By making the path relative to the current file. Fixes #43153 [breaking-change] - if you use `include!` inside a doc test, you'll need to change the path to be relative to the current file rather than relative to the working directory.
2017-08-13Auto merge of #43813 - pengowen123:unused_result, r=estebankbors-1/+42
Fix unused_result lint triggering when a function returns `()`, `!` or an empty enum Also added a test to prevent this from happening again. Fixes #43806
2017-08-13Auto merge of #43630 - Mark-Simulacrum:rustbuild-cleanups, r=alexcrichtonbors-189/+239
Rustbuild cleanups/fixes and improvements Each commit is a standalone change, and can/should be reviewed separately. This adds two new functionalities: - `--target` and `--host` can be passed without changing config.toml, and we'll respect the users' wishes, instead of requiring that all possible targets are passed. - Note that this means that `./x.py clean` won't be quite as wide-spread as before, since it limits itself to the configured hosts, not all hosts. This could be considered a feature as well. - `ignore-git` field in `config.toml` which tells Rustbuild to not attempt to load git hashes from `.git`. This is a precursor to eventual further simplification of the configuration system, but I want to get this merged first so that later work can be made in individual PRs. r? @alexcrichton
2017-08-13Build rustdoc with the native build tripleMark Simulacrum-1/+1
2017-08-13Auto merge of #43348 - kennytm:fix-24658-doc-every-platform, r=alexcrichtonbors-75/+1261
Expose all OS-specific modules in libstd doc. 1. Uses the special `--cfg dox` configuration passed by rustbuild when running `rustdoc`. Changes the `#[cfg(platform)]` into `#[cfg(any(dox, platform))]` so that platform-specific API are visible to rustdoc. 2. Since platform-specific implementations often won't compile correctly on other platforms, `rustdoc` is changed to apply `everybody_loops` to the functions during documentation and doc-test harness. 3. Since platform-specific code are documented on all platforms now, it could confuse users who found a useful API but is non-portable. Also, their examples will be doc-tested, so must be excluded when not testing on the native platform. An undocumented attribute `#[doc(cfg(...))]` is introduced to serve the above purposed. Fixes #24658 (Does _not_ fully implement #1998).
2017-08-12Fix TcpStream::connect_timeout tracking issue numberDavid Tolnay-1/+1
2017-08-13Cargotest needs only one rustdoc.exe to exist on WindowsMark Simulacrum-2/+8