bors
8417d68de5
Auto merge of #68803 - Dylan-DPC:rollup-b4x6ghj, r=Dylan-DPC
...
Rollup of 8 pull requests
Successful merges:
- #68678 (Install robots.txt into rust-docs tarballs)
- #68711 (Added upper bound of what vecs and boxes can allocate)
- #68744 (Do not ICE in `type-alias-impl-trait` with save-analysis)
- #68777 (Clean up E0263 explanation)
- #68787 (Optimize core::ptr::align_offset (part 1))
- #68797 (Fix links to types instead of modules)
- #68798 (Test that `#[track_caller]` as `fn()` respects RT / CTFE equivalence)
- #68800 (Stabilize `core::iter::once_with()`)
Failed merges:
r? @ghost
2020-02-03 18:40:54 +00:00
Dylan DPC
af3c315daf
Rollup merge of #68800 - JohnTitor:stabilize-once-with, r=Centril
...
Stabilize `core::iter::once_with()`
Fixes #57581
FCP: https://github.com/rust-lang/rust/issues/57581#issuecomment-576178031
r? @SimonSapin
2020-02-03 18:58:37 +01:00
Dylan DPC
f17f97d36a
Rollup merge of #68798 - Centril:caller-loc-ctfe-rt-equiv, r=RalfJung
...
Test that `#[track_caller]` as `fn()` respects RT / CTFE equivalence
r? @RalfJung cc @anp @eddyb
2020-02-03 18:58:36 +01:00
Dylan DPC
1028978e8f
Rollup merge of #68797 - GuillaumeGomez:link-to-types, r=Dylan-DPC
...
Fix links to types instead of modules
r? @Dylan-DPC
2020-02-03 18:58:35 +01:00
Dylan DPC
370fd8c1b7
Rollup merge of #68787 - amosonn:patch-1, r=nagisa
...
Optimize core::ptr::align_offset (part 1)
r? @nagisa
See #68616 for main discussion.
2020-02-03 18:58:33 +01:00
Dylan DPC
51c6c25575
Rollup merge of #68777 - GuillaumeGomez:clean-up-e0263, r=Dylan-DPC
...
Clean up E0263 explanation
r? @Dylan-DPC
2020-02-03 18:58:32 +01:00
Dylan DPC
95d1f6ffcd
Rollup merge of #68744 - JohnTitor:fix-ice-save-analysis, r=cramertj
...
Do not ICE in `type-alias-impl-trait` with save-analysis
FIxes #68621
Fixes #68750
2020-02-03 18:58:30 +01:00
Dylan DPC
5e561c2135
Rollup merge of #68711 - hman523:fix-68593, r=Dylan-DPC
...
Added upper bound of what vecs and boxes can allocate
Fixed issue #68593
I added a line of documentation to these two files to reflect that vectors and boxes ensure that they never allocate more than `isize::MAX` bytes.
r? @steveklabnik
2020-02-03 18:58:27 +01:00
Dylan DPC
95df2bcaeb
Rollup merge of #68678 - Mark-Simulacrum:robots, r=pietroalbini
...
Install robots.txt into rust-docs tarballs
Fixes #68677 .
I believe this might just work out from the central-station perspective, but even if it doesn't, this is a prerequisite step anyway.
2020-02-03 18:58:23 +01:00
Yuki Okushi
7e2d7e0bbc
Stabilize core::iter::once_with()
2020-02-04 00:47:04 +09:00
Mazdak Farrokhzad
f0eec88581
track_caller test caller_location ctfe/rt equivalence wrt. fnptrs
2020-02-03 16:15:30 +01:00
Guillaume Gomez
46f6dad101
Fix links to types instead of modules
2020-02-03 16:12:35 +01:00
bors
bdd946df3a
Auto merge of #68665 - eddyb:debuginfo-early-create-var, r=nagisa
...
codegen: create DIVariables ahead of using them with llvm.dbg.declare.
Instead of having `rustc_codegen_llvm` bundle creation of a `DIVariable` and `llvm.dbg.declare` into a single operation, they are now two separate methods, and the `DIVariable` is created earlier, specifically when `mir::VarDebugInfo`s are being partitioned into locals.
While this isn't currently needed, it's a prerequisite for #48300 , which adds fragmented debuginfo, where one `mir::VarDebugInfo` has multiple parts of itself mapped to different `mir::Place`s.
For debuggers to see one composite variable instead of several ones with the same name, we need to create a single `DIVariable` and share it between multiple `llvm.dbg.declare` calls, which are likely pointing to different MIR locals.
That makes the `per_local_var_debug_info` partitioning a good spot to do this in, as we can create *exactly* one `DIVariable` per `mir::VarDebugInfo`, and refer to it as many things as needed.
I'm opening this PR separately because I want to test its perf impact in isolation (see https://github.com/rust-lang/rust/pull/48300#issuecomment-580121438 ).
r? @nagisa or @oli-obk cc @michaelwoerister @nikomatsakis
2020-02-03 13:06:44 +00:00
Eduard-Mihai Burtescu
e35dfad5b8
rustc_codegen_llvm: avoid redundant calls to span_start.
2020-02-03 12:14:22 +02:00
Eduard-Mihai Burtescu
f4b74773c7
rustc_codegen_ssa: convert mir::VarDebugInfo into a custom PerLocalVarDebugInfo.
2020-02-03 12:14:22 +02:00
Eduard-Mihai Burtescu
0b633c82f0
rustc_codegen_ssa: split declare_local into create_dbg_var and dbg_var_addr.
2020-02-03 12:14:21 +02:00
bors
c58e09f138
Auto merge of #68778 - RalfJung:raw-addr-of, r=eddyb
...
add raw-addr-of variant to mir_raw_fat_ptr
As suggested at https://github.com/rust-lang/rust/pull/48300#discussion_r372520388
r? @eddyb
2020-02-03 09:54:09 +00:00
bors
0d34a87722
Auto merge of #68772 - matthewjasper:relate-opt, r=davidtwco
...
Avoid exponential behaviour when relating types
When equating bound types we check subtyping in both directions. Since closures are invariant in their substs, we end up comparing the two types an exponential number of times. If there are no bound variables this isn't needed.
Closes #68061
2020-02-03 06:38:34 +00:00
bors
a2e80300cd
Auto merge of #68756 - JohnTitor:fix-ice-save-analysis-2, r=davidtwco
...
Fix ICE with save-analysis
Fixes #68749
It should be fine since it's the same way as `visit_expr`.
2020-02-03 03:28:08 +00:00
bors
01db581942
Auto merge of #68735 - JohnTitor:fix-ice-0202, r=estebank
...
Use `next_point` to avoid ICE
Fixes #68730
r? @estebank (I think you're familiar with that)
2020-02-03 00:04:16 +00:00
Amos Onn
22b263ae18
Optimize core::ptr::align_offset
...
- As explained in the comment inside mod_inv, it is valid to work mod
`usize::max_value()` right until the end.
2020-02-03 01:03:33 +01:00
Amos Onn
3173cd1473
Optimize core::ptr::align_offset
...
- When calculating the inverse, it's enough to work `mod a/g` instead
of `mod a`.
2020-02-03 01:03:33 +01:00
Amos Onn
e835d0d761
Optimize core::ptr::align_offset
...
- Stopping condition inside mod_inv can be >= instead of >
- Remove intrinsics::unchecked_rem, we are working modulu powers-of-2 so
we can simply mask
2020-02-03 01:03:33 +01:00
bors
8f49d46297
Auto merge of #68720 - wesleywiser:llvm_time_trace, r=davidtwco
...
Add support for enabling the LLVM time-trace feature
I found this helpful while investigating an LLVM performance issue.
Passing `-Z llvm-time-trace` causes a `llvm_timings.json` file to be
created. This file can be inspected in with the Chrome Profiler
tools or with any other compatible tool like SpeedScope.
More information on the LLVM feature:
- https://aras-p.info/blog/2019/01/16/time-trace-timeline-flame-chart-profiler-for-Clang/
- https://reviews.llvm.org/rL357340
2020-02-02 20:33:47 +00:00
Ralf Jung
ee60158440
add raw-addr-of variant to mir_raw_fat_ptr
2020-02-02 20:51:24 +01:00
bors
f43c34a134
Auto merge of #68774 - RalfJung:miri, r=RalfJung
...
bump Miri
Fixes https://github.com/rust-lang/rust/issues/68757
Cc @oli-obk r? @ghost
2020-02-02 16:58:49 +00:00
Guillaume Gomez
019ca55b45
Clean up E0263 explanation
2020-02-02 15:28:18 +01:00
Ralf Jung
8c5bec103f
bump Miri
2020-02-02 14:51:30 +01:00
bors
994e5e7465
Auto merge of #68771 - Centril:rollup-zllcup9, r=Centril
...
Rollup of 5 pull requests
Successful merges:
- #68733 (Update option.rs)
- #68760 (Issue error on `compile-fail` header in UI test)
- #68763 (Do not suggest duplicate bounds)
- #68764 (parser: syntactically allow `self` in all `fn` contexts)
- #68769 (parser: avoid re-wrapping NtItem)
Failed merges:
r? @ghost
2020-02-02 13:16:43 +00:00
Mazdak Farrokhzad
011fb23c58
Rollup merge of #68769 - Centril:unwrap, r=petrochenkov
...
parser: avoid re-wrapping NtItem
r? @petrochenkov
2020-02-02 14:15:53 +01:00
Mazdak Farrokhzad
5951cd3dda
Rollup merge of #68764 - Centril:self-semantic, r=petrochenkov
...
parser: syntactically allow `self` in all `fn` contexts
Part of https://github.com/rust-lang/rust/pull/68728 .
`self` parameters are now *syntactically* allowed as the first parameter irrespective of item context (and in function pointers). Instead, semantic validation (`ast_validation`) is used.
r? @petrochenkov
2020-02-02 14:15:52 +01:00
Mazdak Farrokhzad
2e1790dda1
Rollup merge of #68763 - JohnTitor:do-not-sugg-dup-bounds, r=estebank
...
Do not suggest duplicate bounds
Fixes #68205
Fixes #68695
r? @estebank
2020-02-02 14:15:51 +01:00
Mazdak Farrokhzad
3a7f1edd81
Rollup merge of #68760 - Tyg13:compile_fail_ui_test, r=Centril
...
Issue error on `compile-fail` header in UI test
Fixes #68732
r? @Centril
2020-02-02 14:15:49 +01:00
Mazdak Farrokhzad
f2cc0cc09d
Rollup merge of #68733 - cata0309:patch-1, r=Dylan-DPC
...
Update option.rs
I updated the example of the `expect` examples so they won't contain depressing sentences any more !
2020-02-02 14:15:48 +01:00
Mazdak Farrokhzad
d154bef4d3
parser: avoid re-wrapping NtItem
2020-02-02 13:55:45 +01:00
Mazdak Farrokhzad
71a6f58229
parser: address review comments re. self
.
2020-02-02 13:32:37 +01:00
Matthew Jasper
a606ffdb17
Avoid exponential behaviour when relating types
2020-02-02 12:10:08 +00:00
Yuki Okushi
56ad8bcfe0
Do not suggest duplicate bounds
2020-02-02 18:38:23 +09:00
Mazdak Farrokhzad
8674efdb7c
parser: move restrictions re. self
to ast_validation
.
2020-02-02 10:33:55 +01:00
bors
cef6894572
Auto merge of #68737 - Centril:fix-68710, r=petrochenkov
...
pretty: print attrs in struct expr
Fixes https://github.com/rust-lang/rust/issues/68710 by printing the attributes on struct expression fields.
r? @petrochenkov
cc @dtolnay
2020-02-02 09:19:40 +00:00
Mazdak Farrokhzad
00f0b0cd3a
pretty: print attrs in struct expr
2020-02-02 09:25:54 +01:00
Tyler Lanphear
f6c3894724
compiletest: error if compile-fail
header in ui test.
2020-02-02 02:08:30 -05:00
bors
0cbcb17d33
Auto merge of #68754 - JohnTitor:clippy-up, r=JohnTitor
...
Update Clippy
Fixes #68745
r? @ghost
2020-02-02 06:09:00 +00:00
bors
bc4a339064
Auto merge of #68672 - jonas-schievink:dedup-witness, r=Zoxc
...
Deduplicate types in the generator witness
For the `await-call-tree` benchmark this often reduces the types inside the witness from 12 to 2.
2020-02-02 03:02:41 +00:00
Yuki Okushi
c377ed606c
Fix ICE with save-analysis
2020-02-02 09:23:47 +09:00
Yuki Okushi
ae22bf9d42
Catch more ICEs
2020-02-02 09:02:54 +09:00
Yuki Okushi
632d75e057
Update Clippy
2020-02-02 08:38:28 +09:00
bors
e5b150edaf
Auto merge of #68752 - JohnTitor:rollup-zz3u4xl, r=JohnTitor
...
Rollup of 7 pull requests
Successful merges:
- #68460 (Use BufWriter for emitting MIR)
- #68681 (Suggest path separator for single-colon typos)
- #68688 ([docs] remind bug reporters to update nightly)
- #68704 (Ignore `build` dir formatting)
- #68727 (Remove a comment about pretty printer in formatting tests)
- #68736 (Remove `Alloc` in favor of `AllocRef`)
- #68740 (Do not suggest things named underscore)
Failed merges:
r? @ghost
2020-02-01 23:31:51 +00:00
Yuki Okushi
87bb0c4389
Rollup merge of #68740 - JohnTitor:do-not-sugg-underscore, r=Centril
...
Do not suggest things named underscore
Fixes #68719
r? @estebank
2020-02-02 08:30:21 +09:00
Yuki Okushi
c7332abee2
Rollup merge of #68736 - TimDiekmann:remove-alloc, r=Amanieu
...
Remove `Alloc` in favor of `AllocRef`
`AllocRef` was reexported as `Alloc` in #68529 in order to not break toolstate in the week before the next stable release.
r? @Amanieu
2020-02-02 08:30:19 +09:00