about summary refs log tree commit diff
AgeCommit message (Collapse)AuthorLines
2019-09-14Don't mark expression with attributes as not needing parenthesesMark Rousskov-20/+25
This is not perfectly correct as `#[attr] (5)` will still not lint, but it does seem good enough, in particular as the parentheses in that case are not unambiguously incorrect.
2019-09-14Auto merge of #64456 - Centril:rollup-ytqdwaq, r=Centrilbors-382/+663
Rollup of 17 pull requests Successful merges: - #63846 (Added table containing the system calls used by Instant and SystemTime.) - #64116 (Fix minor typo in docs.) - #64203 (A few cosmetic improvements to code & comments in liballoc and libcore) - #64302 (Shrink `ObligationCauseCode`) - #64372 (use randSecure and randABytes) - #64374 (Box `DiagnosticBuilder`.) - #64375 (Fast path for vec.clear/truncate ) - #64378 (Fix inconsistent link formatting.) - #64384 (Trim rustc-workspace-hack) - #64393 ( declare EnvKey before use to fix build error) - #64420 (Inline `mark_neighbours_as_waiting_from`.) - #64422 (Remove raw string literal quotes from error index descriptions) - #64423 (Add self to .mailmap) - #64425 (typo fix) - #64431 (fn ptr is structural match) - #64435 (codegen: use "_N" (like for other locals) instead of "argN", for argument names.) - #64439 (fix #64430, confusing `owned_box` error message in no_std build) Failed merges: r? @ghost
2019-09-14Rollup merge of #64439 - 12101111:fix-owned-box, r=CentrilMazdak Farrokhzad-26/+47
fix #64430, confusing `owned_box` error message in no_std build Fixes #64430
2019-09-14Rollup merge of #64435 - eddyb:arguments-against-arg, r=rkruppeMazdak Farrokhzad-110/+98
codegen: use "_N" (like for other locals) instead of "argN", for argument names. Based on #64408 (second commit is new), fixing something I mentioned in #64408 (which turned to be an immediate blocker for unifying relevant codepaths). Closes #64408 (by containing it). r? @rkruppe
2019-09-14Rollup merge of #64431 - pnkfelix:issue-63479-fnptr-is-structural-match, ↵Mazdak Farrokhzad-1/+178
r=varkor fn ptr is structural match Make fn ptr always structural match, regardless of whether the formal parameter types or return type are. Fix #63479.
2019-09-14Rollup merge of #64425 - guanqun:typo-fix, r=matthewjasperMazdak Farrokhzad-1/+1
typo fix
2019-09-14Rollup merge of #64423 - ollie27:mailmap, r=Mark-SimulacrumMazdak Farrokhzad-0/+1
Add self to .mailmap
2019-09-14Rollup merge of #64422 - ollie27:error_index_generator_stringify, ↵Mazdak Farrokhzad-1/+1
r=Mark-Simulacrum Remove raw string literal quotes from error index descriptions The error index has unnecessary `r##"` and `"##` around the descriptions from #63721. Removing the `stringify` call removes them. r? @Mark-Simulacrum
2019-09-14Rollup merge of #64420 - nnethercote:inline-mark_neighbours_as_waiting_from, ↵Mazdak Farrokhzad-4/+13
r=Mark-Simulacrum Inline `mark_neighbours_as_waiting_from`. This function is very hot, doesn't get inlined because it's recursive, and the function calls are significant. This commit splits it into inlined and uninlined variants, and uses the inlined variant for the hot call site. This wins several percent on a few benchmarks. r? @nikomatsakis
2019-09-14Rollup merge of #64393 - Wind-River:master_002_envKey, r=alexcrichtonMazdak Farrokhzad-2/+1
declare EnvKey before use to fix build error r? @alexcrichton
2019-09-14Rollup merge of #64384 - mati865:tools_hack, r=alexcrichtonMazdak Farrokhzad-14/+0
Trim rustc-workspace-hack Those dependencies seem no longer necessary. `./x.py test` and `x86_64-gnu-tools` container passed locally so I think this won't hurt.
2019-09-14Rollup merge of #64378 - Rosto75:master, r=jonas-schievinkMazdak Farrokhzad-4/+4
Fix inconsistent link formatting.
2019-09-14Rollup merge of #64375 - kornelski:vecdrop, r=rkruppeMazdak Farrokhzad-13/+17
Fast path for vec.clear/truncate For trivial types like `u8`, `vec.truncate()`/`vec.clear()` relies on the optimizer to remove the loop. This means more work in debug builds, and more work for the optimizer. Avoiding this busywork is exactly what `mem::needs_drop::<T>()` is for.
2019-09-14Rollup merge of #64374 - nnethercote:box-DiagnosticBuilder, r=zackmdavisMazdak Farrokhzad-37/+55
Box `DiagnosticBuilder`. It's a large type -- 176 bytes on 64-bit. And it's passed around and returned from a lot of functions, including within `PResult`. This commit boxes it, which reduces memory traffic. In particular, `PResult` shrinks to 16 bytes in the best case; this reduces instruction counts by up to 2% on various workloads. The commit touches a lot of lines but it's almost all trivial plumbing changes.
2019-09-14Rollup merge of #64372 - Wind-River:master, r=alexcrichtonMazdak Farrokhzad-7/+14
use randSecure and randABytes r? @alexcrichton cc @n-salim
2019-09-14Rollup merge of #64302 - nnethercote:shrink-ObligationCauseCode, r=zackmdavisMazdak Farrokhzad-48/+75
Shrink `ObligationCauseCode` These commits reduce the size of `ObligationCauseCode` from 56 bytes to 32 bytes on 64-bit. This reduces instruction counts on various benchmarks by up to 1%, due to less `memcpy`ing.
2019-09-14Rollup merge of #64203 - alexreg:rush-pr-2, r=centrilMazdak Farrokhzad-111/+109
A few cosmetic improvements to code & comments in liballoc and libcore Factored out from hacking on rustc for work on the REPL. r? @Centril
2019-09-14Rollup merge of #64116 - ZeGentzy:patch-1, r=oli-obkMazdak Farrokhzad-3/+3
Fix minor typo in docs. This comment is prolly refering to the comment in [const_eval_raw_provider](https://github.com/rust-lang/rust/pull/64116/files#diff-e0b58bb6712edaa8595ad7237542c958R616), not itself.
2019-09-14Rollup merge of #63846 - DevQps:32626-document-time-system-calls, r=rkruppeMazdak Farrokhzad-0/+46
Added table containing the system calls used by Instant and SystemTime. # Description See #32626 for a discussion on documenting system calls used by Instant and SystemTime. ## Changes - Added a table containing the system calls used by each platform. EDIT: If I can format this table better (due to the large links) please let me know. I'd also be happy to learn a quick command to generate the docs on my host machine! Currently I am using: `python x.py doc --stage 0 src/libstd` but that gives me some `unrecognized intrinsic` errors. Advice is always welcome :) closes #32626
2019-09-14Update src/liballoc/raw_vec.rsAlexander Regueiro-1/+1
Co-Authored-By: Mazdak Farrokhzad <twingoow@gmail.com>
2019-09-14Auto merge of #64080 - estebank:parse-format-comma, r=zackmdavisbors-10/+18
Be accurate on `format!` parse error expectations Fix https://github.com/rust-lang/rust/issues/57277.
2019-09-13Update value.rsHal Gentz-2/+2
2019-09-14add trailing newline12101111-1/+1
2019-09-14add ui test for #6443012101111-0/+26
2019-09-14fix #6443012101111-26/+21
2019-09-13codegen: use "_N" (like for other locals) instead of "argN", for argument names.Eduard-Mihai Burtescu-55/+56
2019-09-13Auto merge of #63420 - spastorino:place2_5, r=oli-obkbors-1776/+1590
[Place 2.0] Convert Place's projection to a boxed slice This is still work in progress, it's not compiling right now I need to review a bit more to see what's going on but wanted to open the PR to start discussing it. r? @oli-obk
2019-09-13Regression tests for fn ptr and `#[structural_match]` as discussed in #63479.Felix S. Klock II-0/+171
2019-09-13Make fn ptr always structural match, regardless of whether formal types are.Felix S. Klock II-1/+7
Fix #63479.
2019-09-13Update src/libstd/time.rsChristian Veenman-1/+1
Co-Authored-By: Robin Kruppe <robin.kruppe@gmail.com>
2019-09-13Make all projection base names be proj_baseSantiago Pastorino-16/+16
2019-09-13Use if let hereSantiago Pastorino-3/+2
2019-09-13Fix style in commentsSantiago Pastorino-10/+10
2019-09-13Avoid math and use patterns to grab projection baseSantiago Pastorino-35/+24
2019-09-13Add self to .mailmapOliver Middleton-0/+1
2019-09-13Remove raw string literal quotes from error index descriptionsOliver Middleton-1/+1
2019-09-13typo fixGuanqun Lu-1/+1
2019-09-13Auto merge of #64254 - aleksijuvani:fix-macos-sysroot, r=alexcrichtonbors-4/+63
Fix sysroot on macOS when cross-compiling and SDKROOT is set Fixes rust-lang/cargo#7283 Closes rust-lang/cargo#7284 r? @alexcrichton
2019-09-13Inline `mark_neighbours_as_waiting_from`.Nicholas Nethercote-4/+13
This function is very hot, doesn't get inlined because it's recursive, and the function calls are significant. This commit splits it into inlined and uninlined variants, and uses the inlined variant for the hot call site. This wins several percent on a few benchmarks.
2019-09-13Auto merge of #64361 - ehuss:update-cargo, r=alexcrichtonbors-0/+0
Update cargo 11 commits in fe0e5a48b75da2b405c8ce1ba2674e174ae11d5d..9655d70af8a6dddac238e3afa2fec75088c9226f 2019-09-04 00:51:27 +0000 to 2019-09-10 18:16:11 +0000 - Home docs: fix broken links, misspellings, style fixes, clarifications. (rust-lang/cargo#7348) - add readme key to cargos manifest. (rust-lang/cargo#7347) - Explicitly ignore some results (rust-lang/cargo#7340) - Don't resolve std's optional dependencies (rust-lang/cargo#7337) - Add `alloc` and `proc_macro` to libstd crates (rust-lang/cargo#7336) - doc: capitalization change for consistency. (rust-lang/cargo#7334) - Fix test for changes in plugin API. (rust-lang/cargo#7335) - Fix some man pages where the files weren't rebuilt. (rust-lang/cargo#7332) - guide: add section about the cargo home (rust-lang/cargo#7314) - `map_dependencies` is doing a deep clone, so lets make it cheaper (rust-lang/cargo#7326) - don't need to copy this string (rust-lang/cargo#7324)
2019-09-12Auto merge of #64360 - varkor:foreign-items-diagnostic-const-generics, ↵bors-15/+65
r=cramertj Correct the polymorphic extern fn error for const parameters Before, any polymorphism on extern functions was assumed to be type polymorphism.
2019-09-12Destructure instead of using split_atSantiago Pastorino-1/+1
2019-09-12Use foldSantiago Pastorino-7/+4
2019-09-12codegen: be more explicit about setting giving names to allocas.Eduard-Mihai Burtescu-55/+42
2019-09-12Ignore linker env vars set for macOS on iOS targetsAleksi Juvani-3/+20
2019-09-12Auto merge of #64359 - varkor:opaque-ty-in-extern, r=estebankbors-135/+268
Forbid opaque types in `extern "C"` blocks Fixes #64338.
2019-09-12Trim rustc-workspace-hackMateusz Mikuła-14/+0
2019-09-12Remove env vars instead of setting them to an empty stringAleksi Juvani-9/+33
2019-09-12Auto merge of #64328 - Mark-Simulacrum:rustdoc-find-rustc, r=GuillaumeGomezbors-79/+143
rustdoc: change doctests locating rustc binary We previously used the "naive" approach of replacing the `current_exe()`'s file name with rustc, but now load from the sysroot by default (`$sysroot/bin/rustc`). The functionality of locating the sysroot overlaps/is the same as the functionality used by codegen backend loading; this ensures that any failure cases we've introduced are not exceeding those, and that improvements to finding the sysroot for loading codegen backends likewise enhance rustdoc. The second commit adds an unstable `--test-builder` flag to rustdoc, and is largely separate (I can split into separate PR, but it's a simple and related change). This is largely intended for "advanced" users at this point (I'm not sure if we'll ever stabilize it); it permits use of a different rustc binary for rustdoc compilation of doctests than the rustdoc binary used when loading. Note, that this may not be what you want as the parsers and such differ (and rustdoc uses its own libsyntax, etc.). However, I've been told that running doctests in miri may be assisted by this change, so I've implemented it; I'll file a tracking issue for it if there's interest in it (and we land this PR).
2019-09-12Auto merge of #64303 - nnethercote:avoid-more-Symbol-to-string-operations, ↵bors-81/+93
r=petrochenkov Avoid more `Symbol`-to-string operations These commits avoid various `Symbol`-to-string conversions, by doing more operations directly on `Symbol`s. This requires adding a few more static `Symbol`s to the binary. r? @petrochenkov