Pietro Albini
714fd37b8b
Rollup merge of #52778 - ljedrz:readable_serialize, r=kennytm
...
Improve readability of serialize.rs
2018-08-01 10:12:40 +02:00
Pietro Albini
06b91a4901
Rollup merge of #52771 - matklad:patch-1, r=kennytm
...
Clarify thread::park semantics
It took me quite some time to realize that the example is not actually racy, so let's clarify it? :-)
2018-08-01 10:12:38 +02:00
Pietro Albini
dafe33524a
Rollup merge of #52745 - commandline:master, r=oli-obk
...
Update clippy to latest master
r? @oli-obk
There is a regression in the version in current nightly that falsely lints `println!` and `writeln!` that use named arguments, thinking all rhs values for the argument expressions are literals even when they are not. This update includes the fix for that.
2018-08-01 10:12:37 +02:00
Pietro Albini
acff794b68
Rollup merge of #52732 - SimonSapin:spring, r=Mark-Simulacrum
...
Remove unstable and deprecated APIs
2018-08-01 10:12:36 +02:00
Pietro Albini
03df573c57
Rollup merge of #52628 - Mark-Simulacrum:rustdoc-cleanup-1, r=QuietMisdreavus
...
Cleanup some rustdoc code
Commits are mostly individual though some do depend on others.
2018-08-01 10:12:35 +02:00
Pietro Albini
b7ee110ea2
Rollup merge of #52340 - cypher:document-from-trait-in-ffi, r=steveklabnik
...
Document From trait implementations for OsStr, OsString, CString, and CStr
As part of issue #51430 (cc @skade).
The allocation and copy claims should be double-checked.
r? @steveklabnik
2018-08-01 10:12:32 +02:00
Mark Rousskov
0f680b38d0
Fixup test case
2018-07-31 17:55:12 -06:00
Mark Rousskov
4cd004775c
Add dyn to Write
2018-07-31 17:55:12 -06:00
Mark Rousskov
8e65a46268
Cleanup highlighting code
...
Removes some unused code and de-publicizes structs
2018-07-31 17:55:12 -06:00
Mark Rousskov
7bea518d3a
Remove global derive_id and reset_ids functions
...
Previously these functions relied on TLS but we can instead thread the
relevant state through explicitly.
2018-07-31 17:55:12 -06:00
bors
e94df4acb4
Auto merge of #52234 - petrochenkov:macuse2, r=Mark-Simulacrum
...
resolve: Modularize crate-local `#[macro_export] macro_rules`
Based on https://github.com/rust-lang/rust/pull/50911 , cc https://github.com/rust-lang/rust/pull/50911#issuecomment-401151270
`#[macro_export] macro_rules` items are collected from the whole crate and are planted into the root module as items, so the external view of the crate is symmetric with its internal view and something like `$crate::my_macro` where `my_macro` is `#[macro_export] macro_rules` works both locally and from other crates.
Closes https://github.com/rust-lang/rust/issues/52726
2018-07-31 20:52:14 +00:00
Mark Rousskov
2216db9de7
Format code for easier editing
2018-07-31 11:39:04 -06:00
Mark Rousskov
01d95558e6
Further extract error code switch
...
Removes dependency on UnstableFeatures from markdown rendering
2018-07-31 11:39:02 -06:00
Mark Rousskov
03e34f8f81
Remove dependency on error handling from find_testable_code
2018-07-31 11:37:21 -06:00
Mark Rousskov
de5cebdba5
Provide test configuration through struct
...
This is far more sound than passing many different arguments of the same
type.
2018-07-31 11:37:21 -06:00
Mark Rousskov
ad40e4517f
Provide warnings for invalid code blocks in markdown files
...
Previously we would only warn on Rust code but we can also do so when
testing markdown (the diag::Handler is available).
2018-07-31 11:37:21 -06:00
Mark Rousskov
0af5a6be05
Pull out nightly checking to edges
...
Parsing the code block's LangString (```foo) previously checked itself
to see if we were on nightly; that isn't the right place to do so. Move
that check slightly outwards to better abstract LangString.
(This is also an optimization as we avoid the costly environment
variable load of RUSTC_BOOTSTRAP).
2018-07-31 11:37:21 -06:00
bors
f89817997a
Auto merge of #52461 - irinagpopa:safe-llvm, r=nikomatsakis
...
rustc_codegen_llvm: use safe references for LLVM FFI types.
Part of #45274 .
2018-07-31 13:32:32 +00:00
Irina Popa
baff67d51f
rustc_llvm: fix linking on mingw.
2018-07-31 15:36:38 +03:00
bors
ed8d14db99
Auto merge of #50267 - humanenginuity:master, r=alexcrichton
...
Implement inner deref for Option and Result
tracking issue: #50264
2018-07-31 11:20:16 +00:00
bors
8961132010
Auto merge of #52850 - SimonSapin:unstablize, r=alexcrichton
...
Revert "Stabilize to_bytes and from_bytes for integers."
This reverts commit c8f9b84b39
/ PR https://github.com/rust-lang/rust/pull/51835 , and reopens the tracking issue https://github.com/rust-lang/rust/issues/49792 .
These methods were stabilized in Rust 1.29, which is still in Nightly as of this writing. So my understanding is that it is still time to change our minds. Given the ongoing discussion in https://github.com/rust-lang/rust/pull/51919 about possibly renaming these APIs and since 1.29 goes to beta soon, I’d like to revert this stabilization for now until a decision is made in that PR. It’s possible that a decision will be made in time for 1.29, but there is no urgency. At most I expect this functionality to make it into 1.30.
2018-07-31 09:08:33 +00:00
bors
d2652f6c1d
Auto merge of #52630 - Mark-Simulacrum:rustdoc-cleanup-2, r=QuietMisdreavus
...
Delete unused code in rustdoc
Also hid the unused crate exports of rustdoc. This is technically a breaking change but we don't even ship librustdoc in the sysroot so I don't expect breakage.
2018-07-31 07:02:10 +00:00
bors
4fbd4a55f7
Auto merge of #52863 - steveklabnik:update-books, r=Mark-Simulacrum
...
update books for new release
r? @Mark-Simulacrum
2018-07-31 03:30:47 +00:00
bors
cc408fb5be
Auto merge of #52731 - nikomatsakis:issue-52057-inference-variable, r=pnkfelix
...
Issue 52057 — inference variable
Break out the computation of universal region relations and do it during the typeck, where we can handle the resulting constraints that arise.
r? @pnkfelix
2018-07-31 01:25:49 +00:00
Niko Matsakis
b9652aee65
region_infer: rustfmt, pacifying the mercilous tidy
2018-07-31 02:31:41 +02:00
Niko Matsakis
9baf01363c
assert no region obligations on entering custom type op
...
Fixes #51649
2018-07-31 02:31:41 +02:00
Niko Matsakis
68c2a39a72
free RegionBoundPairs earlier and avoid normalizing twice
...
Normalization results are memoized, so this may not be worth it, but it
seems easy enough to do.
2018-07-31 02:31:41 +02:00
Niko Matsakis
490928f709
remove region_bound_pairs
from FRR as they are not needed later
2018-07-31 02:31:41 +02:00
Niko Matsakis
1e1f18ddba
make a free fn for creating the URR
2018-07-31 02:31:41 +02:00
Niko Matsakis
d42bc58b1d
add regression test for #52057
...
Fixes #52057
2018-07-31 02:31:41 +02:00
Niko Matsakis
d1e67fcacd
remove universal-region-relation computation from universal_regions
2018-07-31 02:31:40 +02:00
Niko Matsakis
3bca170bc7
introduce, but do not use, free_region_relation
computation
...
This duplicates, effectively, existing code in the universal regions
computation.
2018-07-31 02:26:06 +02:00
Mark Rousskov
620c4fdf53
Delete unused code in rustdoc
2018-07-30 16:33:56 -06:00
Irina Popa
69ed6b928c
rustc_codegen_llvm: fix ownership of DIBuilder.
2018-07-30 20:35:14 +03:00
Irina Popa
54c98ab0dd
rustc_codegen_llvm: fix ownership of Builder.
2018-07-30 20:35:11 +03:00
Irina Popa
265f2fa4de
rustc_codegen_llvm: fix tidy errors.
2018-07-30 20:35:08 +03:00
Irina Popa
ba006440ee
rustc_codegen_llvm: use safe references for ThinLTOData.
2018-07-30 20:34:51 +03:00
Irina Popa
2e3a6af7fa
rustc_codegen_llvm: use safe references for ThinLTOBuffer.
2018-07-30 20:10:47 +03:00
Irina Popa
ab4f93c742
rustc_codegen_llvm: use safe references for ModuleBuffer.
2018-07-30 20:10:45 +03:00
Irina Popa
b643e5144e
rustc_codegen_llvm: use safe references for RustArchiveMember.
2018-07-30 20:10:44 +03:00
Irina Popa
c7669dff2a
rustc_codegen_llvm: use safe references for ArchiveChild.
2018-07-30 20:10:43 +03:00
Irina Popa
e551ed9033
rustc_codegen_llvm: use safe references for ArchiveIterator.
2018-07-30 20:10:42 +03:00
Irina Popa
894467e5b4
rustc_codegen_llvm: use safe references for Linker.
2018-07-30 20:10:41 +03:00
Irina Popa
2c1d7fbb83
rustc_codegen_llvm: use safe references for SectionIterator.
2018-07-30 20:10:39 +03:00
Irina Popa
e22eebaf2b
rustc_codegen_llvm: use safe references for PassManager.
2018-07-30 20:10:38 +03:00
Irina Popa
0ab3444540
rustc_codegen_llvm: use safe references for OperandBundleDef.
2018-07-30 20:10:37 +03:00
Irina Popa
92af9694b9
rustc_codegen_llvm: use safe mutable references for output parameters.
2018-07-30 20:10:36 +03:00
Irina Popa
c1eeb69ce8
rustc_codegen_llvm: use safe references for RustString.
2018-07-30 20:10:34 +03:00
Irina Popa
44ae6f1909
rustc_codegen_llvm: use safe references for Twine, DiagnosticInfo, SMDiagnostic.
2018-07-30 20:10:33 +03:00
Irina Popa
41d7d8e35e
rustc_codegen_llvm: use safe references for Archive.
2018-07-30 20:10:32 +03:00