]> git.lizzy.rs Git - rust.git/log
rust.git
4 years agoDon't access a static just for its size and alignment
Oliver Scherer [Thu, 25 Jul 2019 17:29:48 +0000 (19:29 +0200)]
Don't access a static just for its size and alignment

4 years agoAuto merge of #62944 - RalfJung:miri, r=oli-obk
bors [Thu, 25 Jul 2019 06:14:48 +0000 (06:14 +0000)]
Auto merge of #62944 - RalfJung:miri, r=oli-obk

bump Miri

Fixes https://github.com/rust-lang/rust/issues/62919.

r? @oli-obk

4 years agoAuto merge of #62961 - Centril:rollup-kydeswa, r=Centril
bors [Thu, 25 Jul 2019 02:04:55 +0000 (02:04 +0000)]
Auto merge of #62961 - Centril:rollup-kydeswa, r=Centril

Rollup of 9 pull requests

Successful merges:

 - #61727 (Add binary dependencies to dep-info files)
 - #62736 (Polonius: fix some cases of `killed` fact generation, and most of the `ui` test suite)
 - #62758 (ci: Install clang on Windows through tarballs)
 - #62784 (Add riscv32i-unknown-none-elf target)
 - #62814 (add support for hexagon-unknown-linux-musl)
 - #62827 (Don't link mcjit/interpreter LLVM components)
 - #62901 (cleanup: Remove `extern crate serialize as rustc_serialize`s)
 - #62903 (Support SDKROOT env var on iOS)
 - #62906 (Require a value for configure --debuginfo-level)

Failed merges:

 - #62910 (cleanup: Remove lint annotations in specific crates that are already enforced by rustbuild)

r? @ghost

4 years agoRollup merge of #62906 - cuviper:debuginfo-level, r=Mark-Simulacrum
Mazdak Farrokhzad [Wed, 24 Jul 2019 23:05:07 +0000 (01:05 +0200)]
Rollup merge of #62906 - cuviper:debuginfo-level, r=Mark-Simulacrum

Require a value for configure --debuginfo-level

In `configure.py`, using the `o` function creates an enable/disable
boolean setting, and writes `true` or `false` in `config.toml`. However,
rustbuild is expecting to parse a `u32` debuginfo level. We can change
to the `v` function to have the options require a value.

4 years agoRollup merge of #62903 - swolchok:ios-sdkroot, r=alexcrichton
Mazdak Farrokhzad [Wed, 24 Jul 2019 23:05:05 +0000 (01:05 +0200)]
Rollup merge of #62903 - swolchok:ios-sdkroot, r=alexcrichton

Support SDKROOT env var on iOS

Following what clang does (https://github.com/llvm/llvm-project/blob/296a80102a9b72c3eda80558fb78a3ed8849b341/clang/lib/Driver/ToolChains/Darwin.cpp#L1661-L1678), allow allow SDKROOT to tell us where the Apple SDK lives so we don't have to invoke xcrun.

Replaces #62551.

4 years agoRollup merge of #62901 - petrochenkov:serde, r=Centril
Mazdak Farrokhzad [Wed, 24 Jul 2019 23:05:03 +0000 (01:05 +0200)]
Rollup merge of #62901 - petrochenkov:serde, r=Centril

cleanup: Remove `extern crate serialize as rustc_serialize`s

4 years agoRollup merge of #62827 - nikic:llvm-components, r=alexcrichton
Mazdak Farrokhzad [Wed, 24 Jul 2019 23:05:02 +0000 (01:05 +0200)]
Rollup merge of #62827 - nikic:llvm-components, r=alexcrichton

Don't link mcjit/interpreter LLVM components

We don't use these. Drop related unused ExecutionEngine header uses.

As some drive-by cleanup drop the unused `EnableARMEHABI` global and remove an outdated version check for the hexagon component.

r? @alexcrichton

4 years agoRollup merge of #62814 - androm3da:hexagon_19jul_2019, r=alexcrichton
Mazdak Farrokhzad [Wed, 24 Jul 2019 23:05:00 +0000 (01:05 +0200)]
Rollup merge of #62814 - androm3da:hexagon_19jul_2019, r=alexcrichton

add support for hexagon-unknown-linux-musl

4 years agoRollup merge of #62784 - Disasm:riscv32i, r=estebank
Mazdak Farrokhzad [Wed, 24 Jul 2019 23:04:59 +0000 (01:04 +0200)]
Rollup merge of #62784 - Disasm:riscv32i, r=estebank

Add riscv32i-unknown-none-elf target

This target is likely to be useful for constrained FPGA soft-cores, such as picorv32 and HeavyX.

4 years agoRollup merge of #62758 - alexcrichton:llvm-tarball-windows, r=pietroalbini
Mazdak Farrokhzad [Wed, 24 Jul 2019 23:04:57 +0000 (01:04 +0200)]
Rollup merge of #62758 - alexcrichton:llvm-tarball-windows, r=pietroalbini

ci: Install clang on Windows through tarballs

Previously we used the executables built the LLVM project but these
executables are difficult to run in a CI environment, they can
accidentally pollute global state, etc. In testing some of the possible
4-core machine environments for Azure this step would frequently cause
issues.

To assuage these future issues and hopefully make builds slightly more
self-contained, this commit changes to install from a tarball instead.
The tarball isn't provided by LLVM itself, but we use the offical LLVM
installer to extract itself and then we pack up the LLVM installation
directory into the tarball.

4 years agoRollup merge of #62736 - lqd:polonius_tests3, r=matthewjasper
Mazdak Farrokhzad [Wed, 24 Jul 2019 23:04:55 +0000 (01:04 +0200)]
Rollup merge of #62736 - lqd:polonius_tests3, r=matthewjasper

Polonius: fix some cases of `killed` fact generation, and most of the `ui` test suite

Since basic Polonius functionality was re-enabled by @matthewjasper in #54468, some tests were still failing in the polonius compare-mode.

This PR fixes all but one test in the `ui` suite by:
- fixing some bugs in the fact generation code, related to the `killed` relation: Polonius would incorrectly reject some NLL-accepted code, because of these missing `killed` facts.
- ignoring some tests in the polonius compare-mode: a lot of those manually test the NLL or migrate mode, and the failures were mostly artifacts of the test revisions, e.g. that `-Z polonius` requires full NLLs. Some others were also both failing with NLL and succeeding with Polonius, which we can't encode in tests at the moment.
- blessing the output of some tests: whenever Polonius and NLL have basically the same errors, except for diagnostics differences, the Polonius output is blessed. Whenever we've advanced into a less experimental phase, we'll want to revisit these cases (much like we did on the NLL test suite last year) to specifically work on diagnostics.

Fact generation changes:
- we now kill loans on the destination place of `Call` terminators
- we now kill loans on the locals destroyed by `StorageDead`
- we now also handle assignments to projections: killing the loans on a either a deref-ed local, or the ones whose `borrowed_place` conflicts with the current place.

One failing test remains: an overflow during fact generation, on a case of polymorphic recursion (and which I'll continue investigating later).

This adds some tests for the fact generation changes, with some simple Polonius cases similar to the existing smoke tests, but also for some cases encountered in the wild (in the `rand` crate for example).

A more detailed write-up is available [here](https://hackmd.io/CjYB0fs4Q9CweyeTdKWyEg?view) with an explanation for each test failure, the steps taken to resolve it (as a commit in the current PR), NLL and Polonius outputs (and diff), etc.

Since they've worked on this before, and we've discussed some of these failures together:

r? @matthewjasper

4 years agoRollup merge of #61727 - Mark-Simulacrum:crate-deps-in-deps, r=alexcrichton
Mazdak Farrokhzad [Wed, 24 Jul 2019 23:04:54 +0000 (01:04 +0200)]
Rollup merge of #61727 - Mark-Simulacrum:crate-deps-in-deps, r=alexcrichton

Add binary dependencies to dep-info files

I'm not sure about the lack of incremental-tracking here, but since I'm pretty sure this runs on every compile anyway it might not matter? If there's a better place/way to get at the information I want, I'm happy to refactor the code to match.

r? @alexcrichton

4 years agore-enable debug checks in Miri
Ralf Jung [Wed, 24 Jul 2019 18:47:24 +0000 (20:47 +0200)]
re-enable debug checks in Miri

4 years agobump Miri
Ralf Jung [Wed, 24 Jul 2019 18:18:15 +0000 (20:18 +0200)]
bump Miri

4 years agoAdd comment
Scott Wolchok [Wed, 24 Jul 2019 17:28:14 +0000 (10:28 -0700)]
Add comment

4 years agoAuto merge of #62935 - Centril:rollup-hzj9att, r=Centril
bors [Wed, 24 Jul 2019 15:59:00 +0000 (15:59 +0000)]
Auto merge of #62935 - Centril:rollup-hzj9att, r=Centril

Rollup of 10 pull requests

Successful merges:

 - #62641 (Regenerate character tables for Unicode 12.1)
 - #62716 (state also in the intro that UnsafeCell has no effect on &mut)
 - #62738 (Remove uses of mem::uninitialized from std::sys::cloudabi)
 - #62772 (Suggest trait bound on type parameter when it is unconstrained)
 - #62890 (Normalize use of backticks in compiler messages for libsyntax/*)
 - #62905 (Normalize use of backticks in compiler messages for doc)
 - #62916 (Add test `self-in-enum-definition`)
 - #62917 (Always emit trailing slash error)
 - #62926 (Fix typo in mem::uninitialized doc)
 - #62927 (use PanicMessage in MIR, kill InterpError::description)

Failed merges:

r? @ghost

4 years agoGate binary dependency information behind -Zbinary-dep-depinfo
Mark Rousskov [Wed, 24 Jul 2019 15:00:09 +0000 (11:00 -0400)]
Gate binary dependency information behind -Zbinary-dep-depinfo

4 years agoAdd binary dependencies to dep-info files
Mark Rousskov [Mon, 10 Jun 2019 16:18:53 +0000 (10:18 -0600)]
Add binary dependencies to dep-info files

4 years agoRollup merge of #62927 - RalfJung:panic, r=oli-obk
Mazdak Farrokhzad [Wed, 24 Jul 2019 14:13:23 +0000 (16:13 +0200)]
Rollup merge of #62927 - RalfJung:panic, r=oli-obk

use PanicMessage in MIR, kill InterpError::description

r? @oli-obk @eddyb
Cc @saleemjaffer https://github.com/rust-rfcs/const-eval/issues/4

4 years agoRollup merge of #62926 - Smibu:fix-typo, r=jonas-schievink
Mazdak Farrokhzad [Wed, 24 Jul 2019 14:13:22 +0000 (16:13 +0200)]
Rollup merge of #62926 - Smibu:fix-typo, r=jonas-schievink

Fix typo in mem::uninitialized doc

4 years agoRollup merge of #62917 - estebank:trailing-slash, r=matklad
Mazdak Farrokhzad [Wed, 24 Jul 2019 14:13:20 +0000 (16:13 +0200)]
Rollup merge of #62917 - estebank:trailing-slash, r=matklad

Always emit trailing slash error

Fix #62913.

r? @petrochenkov

4 years agoRollup merge of #62916 - Centril:self-in-enum-def, r=oli-obk
Mazdak Farrokhzad [Wed, 24 Jul 2019 14:13:18 +0000 (16:13 +0200)]
Rollup merge of #62916 - Centril:self-in-enum-def, r=oli-obk

Add test `self-in-enum-definition`

Apparently there was no test covering this...

r? @oli-obk
cc @petrochenkov

4 years agoRollup merge of #62905 - fakenine:normalize_use_of_backticks_compiler_messages_p16...
Mazdak Farrokhzad [Wed, 24 Jul 2019 14:13:17 +0000 (16:13 +0200)]
Rollup merge of #62905 - fakenine:normalize_use_of_backticks_compiler_messages_p16, r=Centril

Normalize use of backticks in compiler messages for doc

https://github.com/rust-lang/rust/issues/60532

4 years agoRollup merge of #62890 - fakenine:normalize_use_of_backticks_compiler_messages_p15...
Mazdak Farrokhzad [Wed, 24 Jul 2019 14:13:15 +0000 (16:13 +0200)]
Rollup merge of #62890 - fakenine:normalize_use_of_backticks_compiler_messages_p15, r=Centril

Normalize use of backticks in compiler messages for libsyntax/*

https://github.com/rust-lang/rust/issues/60532

4 years agoRollup merge of #62772 - estebank:trait-bound, r=matthewjasper
Mazdak Farrokhzad [Wed, 24 Jul 2019 14:13:14 +0000 (16:13 +0200)]
Rollup merge of #62772 - estebank:trait-bound, r=matthewjasper

Suggest trait bound on type parameter when it is unconstrained

Given

```
trait Foo { fn method(&self) {} }

fn call_method<T>(x: &T) {
    x.method()
}
```

suggest constraining `T` with `Foo`.

Fix #21673, fix #41030.

4 years agoRollup merge of #62738 - nathanwhit:fix_mem_uninit_cloudabi, r=RalfJung
Mazdak Farrokhzad [Wed, 24 Jul 2019 14:13:12 +0000 (16:13 +0200)]
Rollup merge of #62738 - nathanwhit:fix_mem_uninit_cloudabi, r=RalfJung

Remove uses of mem::uninitialized from std::sys::cloudabi

Addresses #62397 for std::sys::cloudabi, excluding the tests within cloudabi, which will be a separate PR

4 years agoRollup merge of #62716 - RalfJung:unsafe-cell, r=Centril
Mazdak Farrokhzad [Wed, 24 Jul 2019 14:13:09 +0000 (16:13 +0200)]
Rollup merge of #62716 - RalfJung:unsafe-cell, r=Centril

state also in the intro that UnsafeCell has no effect on &mut

Just to be extra sure.

4 years agoRollup merge of #62641 - cuviper:unicode-12.1, r=matklad
Mazdak Farrokhzad [Wed, 24 Jul 2019 14:13:07 +0000 (16:13 +0200)]
Rollup merge of #62641 - cuviper:unicode-12.1, r=matklad

Regenerate character tables for Unicode 12.1

4 years agoAuto merge of #62908 - fakenine:normalize_use_of_backticks_compiler_messages_p17...
bors [Wed, 24 Jul 2019 10:03:20 +0000 (10:03 +0000)]
Auto merge of #62908 - fakenine:normalize_use_of_backticks_compiler_messages_p17, r=alexreg

normalize use of backticks for compiler messages in remaining modules

https://github.com/rust-lang/rust/issues/60532

4 years agoApply suggestions from code review
Ralf Jung [Wed, 24 Jul 2019 09:45:39 +0000 (11:45 +0200)]
Apply suggestions from code review

Co-Authored-By: Mazdak Farrokhzad <twingoow@gmail.com>
4 years agofix unused import
Ralf Jung [Wed, 24 Jul 2019 09:43:59 +0000 (11:43 +0200)]
fix unused import

4 years agoRefer to #50072 re. hack.
Mazdak Farrokhzad [Wed, 24 Jul 2019 09:36:17 +0000 (11:36 +0200)]
Refer to #50072 re. hack.

4 years agoFix typo in mem::uninitialized doc
Mika Lehtinen [Wed, 24 Jul 2019 08:34:30 +0000 (11:34 +0300)]
Fix typo in mem::uninitialized doc

4 years agouse PanicMessage type for MIR assertion errors
Ralf Jung [Wed, 24 Jul 2019 08:24:55 +0000 (10:24 +0200)]
use PanicMessage type for MIR assertion errors

4 years agokill InterpError::description
Ralf Jung [Wed, 24 Jul 2019 07:27:20 +0000 (09:27 +0200)]
kill InterpError::description

4 years agodo not use InterpError::description outside librustc::mir
Ralf Jung [Wed, 24 Jul 2019 07:12:21 +0000 (09:12 +0200)]
do not use InterpError::description outside librustc::mir

4 years agoAdd test self-in-enum-definition
Mazdak Farrokhzad [Tue, 23 Jul 2019 23:24:19 +0000 (01:24 +0200)]
Add test self-in-enum-definition

4 years agoAlways emit trailing slash error
Esteban Küber [Tue, 23 Jul 2019 23:28:20 +0000 (16:28 -0700)]
Always emit trailing slash error

4 years agonormalize use of backticks for compiler messages in remaining modules
Samy Kacimi [Tue, 23 Jul 2019 19:26:01 +0000 (21:26 +0200)]
normalize use of backticks for compiler messages in remaining modules

https://github.com/rust-lang/rust/issues/60532

4 years agofix check
Scott Wolchok [Tue, 23 Jul 2019 20:37:17 +0000 (13:37 -0700)]
fix check

4 years agoAuto merge of #62902 - Mark-Simulacrum:rollup-mxfk0mm, r=Mark-Simulacrum
bors [Tue, 23 Jul 2019 19:50:46 +0000 (19:50 +0000)]
Auto merge of #62902 - Mark-Simulacrum:rollup-mxfk0mm, r=Mark-Simulacrum

Rollup of 14 pull requests

Successful merges:

 - #60951 (more specific errors in src/librustc/mir/interpret/error.rs)
 - #62523 (Delay bug to resolve HRTB ICE)
 - #62656 (explain how to search in slice without owned data)
 - #62791 (Handle more cases of typos misinterpreted as type ascription)
 - #62804 (rustc_typeck: improve diagnostics for _ const/static declarations)
 - #62808 (Revert "Disable stack probing for gnux32.")
 - #62817 (Tweak span for variant not found error)
 - #62842 (Add tests for issue-58887)
 - #62851 (move unescape module to rustc_lexer)
 - #62859 (Place::as_place_ref is now Place::as_ref)
 - #62869 (add rustc_private as a proper language feature gate)
 - #62880 (normalize use of backticks in compiler messages for librustc_allocator)
 - #62885 (Change "OSX" to "macOS")
 - #62889 (Update stage0.txt)

Failed merges:

r? @ghost

4 years agoRequire a value for configure --debuginfo-level
Josh Stone [Tue, 23 Jul 2019 19:04:31 +0000 (12:04 -0700)]
Require a value for configure --debuginfo-level

In `configure.py`, using the `o` function creates an enable/disable
boolean setting, and writes `true` or `false` in `config.toml`. However,
rustbuild is expecting to parse a `u32` debuginfo level. We can change
to the `v` function to have the options require a value.

4 years agoNormalize use of backticks in compiler messages for doc
Samy Kacimi [Tue, 23 Jul 2019 18:06:00 +0000 (20:06 +0200)]
Normalize use of backticks in compiler messages for doc

https://github.com/rust-lang/rust/issues/60532

4 years agoNormalize use of backticks in compiler messages for libsyntax/*
Samy Kacimi [Tue, 23 Jul 2019 18:03:20 +0000 (20:03 +0200)]
Normalize use of backticks in compiler messages for libsyntax/*

https://github.com/rust-lang/rust/issues/60532

4 years agoUse raw pointers in std::sys::cloudabi when passing MaybeUninit values
Nathan [Tue, 23 Jul 2019 17:51:28 +0000 (13:51 -0400)]
Use raw pointers in std::sys::cloudabi when passing MaybeUninit values

4 years agoCleanup std::sys::cloudabi
Nathan [Tue, 23 Jul 2019 14:20:33 +0000 (10:20 -0400)]
Cleanup std::sys::cloudabi

4 years agoRollup merge of #62889 - git-iso:patch-1, r=jonas-schievink
Mark Rousskov [Tue, 23 Jul 2019 16:51:22 +0000 (12:51 -0400)]
Rollup merge of #62889 - git-iso:patch-1, r=jonas-schievink

Update stage0.txt

Grammar.

4 years agoRollup merge of #62885 - atouchet:macos, r=alexcrichton
Mark Rousskov [Tue, 23 Jul 2019 16:51:21 +0000 (12:51 -0400)]
Rollup merge of #62885 - atouchet:macos, r=alexcrichton

Change "OSX" to "macOS"

Apple no longer uses the OS X branding.

4 years agoRollup merge of #62880 - fakenine:normalize_use_of_backticks_compiler_messages_p14...
Mark Rousskov [Tue, 23 Jul 2019 16:51:19 +0000 (12:51 -0400)]
Rollup merge of #62880 - fakenine:normalize_use_of_backticks_compiler_messages_p14, r=Centril

normalize use of backticks in compiler messages for librustc_allocator

https://github.com/rust-lang/rust/issues/60532

4 years agoRollup merge of #62869 - matklad:feature-gate, r=Mark-Simulacrum
Mark Rousskov [Tue, 23 Jul 2019 16:51:18 +0000 (12:51 -0400)]
Rollup merge of #62869 - matklad:feature-gate, r=Mark-Simulacrum

add rustc_private as a proper language feature gate

At the moment, `rustc_private` as a (library) feature exists by
accident: `char::is_xid_start`, `char::is_xid_continue` methods in
libcore define it.

cc https://rust-lang.zulipchat.com/#narrow/stream/131828-t-compiler/topic/How.20to.20declare.20new.20langauge.20feature.3F

I don't know if this is at all reasonable, but at least tests seem to pass locally. That probably means that we can remove/rename to something more resonable the feature in libcore in the next release?

4 years agoRollup merge of #62859 - spastorino:rename-to-as-ref, r=Centril
Mark Rousskov [Tue, 23 Jul 2019 16:51:16 +0000 (12:51 -0400)]
Rollup merge of #62859 - spastorino:rename-to-as-ref, r=Centril

Place::as_place_ref is now Place::as_ref

r? @oli-obk

4 years agoRollup merge of #62851 - matklad:unescape, r=petrochenkov
Mark Rousskov [Tue, 23 Jul 2019 16:51:15 +0000 (12:51 -0400)]
Rollup merge of #62851 - matklad:unescape, r=petrochenkov

move unescape module to rustc_lexer

It makes sense to keep the definition of escape sequences closer to the lexer itself, and it is also a bit of code that I would like to share with rust-analyzer.

r? @petrochenkov

4 years agoRollup merge of #62842 - JohnTitor:test-for-58887, r=alexreg
Mark Rousskov [Tue, 23 Jul 2019 16:51:13 +0000 (12:51 -0400)]
Rollup merge of #62842 - JohnTitor:test-for-58887, r=alexreg

Add tests for issue-58887

Closes #58887

4 years agoRollup merge of #62817 - estebank:variant-sp, r=matthewjasper
Mark Rousskov [Tue, 23 Jul 2019 16:51:12 +0000 (12:51 -0400)]
Rollup merge of #62817 - estebank:variant-sp, r=matthewjasper

Tweak span for variant not found error

4 years agoRollup merge of #62808 - crlf0710:gnux32_stack_probe, r=nikic
Mark Rousskov [Tue, 23 Jul 2019 16:51:10 +0000 (12:51 -0400)]
Rollup merge of #62808 - crlf0710:gnux32_stack_probe, r=nikic

Revert "Disable stack probing for gnux32."

This reverts commit 42d652ecd6709b756d95fc42615b166aacd2ea07. (#59686)

Closes #59674.

4 years agoRollup merge of #62804 - lundibundi:help-infer-const-static, r=eddyb
Mark Rousskov [Tue, 23 Jul 2019 16:51:09 +0000 (12:51 -0400)]
Rollup merge of #62804 - lundibundi:help-infer-const-static, r=eddyb

rustc_typeck: improve diagnostics for _ const/static declarations

This continues https://github.com/rust-lang/rust/pull/62694 and adds type suggestions to const/static declarations with `_` type.

r? @eddyb

4 years agoRollup merge of #62791 - estebank:type-ascription, r=petrochenkov
Mark Rousskov [Tue, 23 Jul 2019 16:51:07 +0000 (12:51 -0400)]
Rollup merge of #62791 - estebank:type-ascription, r=petrochenkov

Handle more cases of typos misinterpreted as type ascription

Fix #60933, #54516.

CC #47666, #34255, #48016.

4 years agoRollup merge of #62656 - RalfJung:contains-no-own, r=Dylan-DPC
Mark Rousskov [Tue, 23 Jul 2019 16:51:05 +0000 (12:51 -0400)]
Rollup merge of #62656 - RalfJung:contains-no-own, r=Dylan-DPC

explain how to search in slice without owned data

Cc https://github.com/rust-lang/rust/issues/62367

4 years agoRollup merge of #62523 - pnkfelix:delay-bug-to-resolve-issue-62203-ice, r=varkor
Mark Rousskov [Tue, 23 Jul 2019 16:51:04 +0000 (12:51 -0400)]
Rollup merge of #62523 - pnkfelix:delay-bug-to-resolve-issue-62203-ice, r=varkor

Delay bug to resolve HRTB ICE

Fix #62203

4 years agoRollup merge of #60951 - saleemjaffer:mir_better_error_enum, r=oli-obk
Mark Rousskov [Tue, 23 Jul 2019 16:51:02 +0000 (12:51 -0400)]
Rollup merge of #60951 - saleemjaffer:mir_better_error_enum, r=oli-obk

more specific errors in src/librustc/mir/interpret/error.rs

Implements [this](https://github.com/rust-rfcs/const-eval/issues/4)

4 years agocleanup: Remove `extern crate serialize as rustc_serialize`s
Vadim Petrochenkov [Tue, 23 Jul 2019 15:50:47 +0000 (18:50 +0300)]
cleanup: Remove `extern crate serialize as rustc_serialize`s

4 years agoAuto merge of #62823 - RalfJung:miri, r=oli-obk
bors [Tue, 23 Jul 2019 15:55:26 +0000 (15:55 +0000)]
Auto merge of #62823 - RalfJung:miri, r=oli-obk

update Miri

Fixes https://github.com/rust-lang/rust/issues/62802

r? @oli-obk @eddyb

4 years agoUpdate stage0.txt
git-iso [Tue, 23 Jul 2019 15:07:06 +0000 (11:07 -0400)]
Update stage0.txt

Fix columns.

4 years agoModify CloudABI ReentrantMutex to use MaybeUninit
Nathan [Mon, 22 Jul 2019 21:31:35 +0000 (17:31 -0400)]
Modify CloudABI ReentrantMutex to use MaybeUninit

Remove uses of mem::uninitialized, which is now deprecated

4 years agorenames EvalErrorPanic to PanicMessage
Saleem Jaffer [Tue, 23 Jul 2019 11:12:46 +0000 (16:42 +0530)]
renames EvalErrorPanic to PanicMessage

4 years agoAuto merge of #61779 - Zoxc:sharded, r=oli-obk
bors [Tue, 23 Jul 2019 09:58:48 +0000 (09:58 +0000)]
Auto merge of #61779 - Zoxc:sharded, r=oli-obk

Use sharded maps for interning

Cuts down runtime from 5.5s to 3.8s for non-incremental `syntex_syntax` check builds with 16 threads / 8 cores.

r? @eddyb

4 years agomoving some variants from InterpError to EvalErrorPanic
Saleem Jaffer [Sat, 20 Jul 2019 13:27:46 +0000 (18:57 +0530)]
moving some variants from InterpError to EvalErrorPanic

4 years agoUpdate src/librustc_lexer/src/lib.rs
Aleksey Kladov [Tue, 23 Jul 2019 07:38:18 +0000 (10:38 +0300)]
Update src/librustc_lexer/src/lib.rs

Co-Authored-By: Ralf Jung <post@ralfj.de>
4 years agoUpdate stage0.txt
git-iso [Tue, 23 Jul 2019 03:30:21 +0000 (23:30 -0400)]
Update stage0.txt

Grammar.

4 years agoRemove uses of mem::uninitialized in std::sys::cloudabi
Nathan [Mon, 22 Jul 2019 21:17:37 +0000 (17:17 -0400)]
Remove uses of mem::uninitialized in std::sys::cloudabi

Usages still appear in cloudabi tests and in the reentrant mutex implementation

4 years agoChange "OSX" to "macOS"
Alex Touchet [Mon, 22 Jul 2019 23:16:59 +0000 (16:16 -0700)]
Change "OSX" to "macOS"

4 years agonormalize use of backticks in compiler messages for librustc_allocator
Samy Kacimi [Mon, 22 Jul 2019 20:52:13 +0000 (22:52 +0200)]
normalize use of backticks in compiler messages for librustc_allocator

https://github.com/rust-lang/rust/issues/60532

4 years agoAuto merge of #62873 - Centril:rollup-ncnuelj, r=Centril
bors [Mon, 22 Jul 2019 17:08:25 +0000 (17:08 +0000)]
Auto merge of #62873 - Centril:rollup-ncnuelj, r=Centril

Rollup of 14 pull requests

Successful merges:

 - #62709 (Test that maplike FromIter satisfies uniqueness)
 - #62713 (Stabilize <*mut _>::cast and <*const _>::cast)
 - #62746 ( do not use assume_init in std::io)
 - #62787 (Fix typo in src/libstd/net/udp.rs doc comment)
 - #62788 (normalize use of backticks in compiler messages for libcore/ptr)
 - #62799 (use const array repeat expressions for uninit_array)
 - #62810 (normalize use of backticks in compiler messages for librustc_lint)
 - #62812 (normalize use of backticks in compiler messages for librustc_metadata)
 - #62832 (normalize use of backticks in compiler messages for librustc_incremental)
 - #62845 (read: fix doc comment)
 - #62853 (normalize use of backticks in compiler messages for librustc/hir)
 - #62854 (Fix typo in Unicode character name)
 - #62858 (Change wrong variable name.)
 - #62870 (fix lexing of comments with many \r)

Failed merges:

r? @ghost

4 years agoadd support for hexagon-unknown-linux-musl
Brian Cain [Fri, 10 Aug 2018 17:01:18 +0000 (12:01 -0500)]
add support for hexagon-unknown-linux-musl

4 years agoRollup merge of #62870 - matklad:issue-62863, r=petrochenkov
Mazdak Farrokhzad [Mon, 22 Jul 2019 13:32:29 +0000 (15:32 +0200)]
Rollup merge of #62870 - matklad:issue-62863, r=petrochenkov

fix lexing of comments with many \r

closes #62863

4 years agoRollup merge of #62858 - Rosto75:master, r=jonas-schievink
Mazdak Farrokhzad [Mon, 22 Jul 2019 13:32:27 +0000 (15:32 +0200)]
Rollup merge of #62858 - Rosto75:master, r=jonas-schievink

Change wrong variable name.

r? @steveklabnik

4 years agoRollup merge of #62854 - andrewda:fix-unicode-name, r=petrochenkov
Mazdak Farrokhzad [Mon, 22 Jul 2019 13:32:26 +0000 (15:32 +0200)]
Rollup merge of #62854 - andrewda:fix-unicode-name, r=petrochenkov

Fix typo in Unicode character name

There's a small typo in the Unicode character definitions: "Latin Epigraphic Letter Dideways" should be "Latin Epigraphic Letter Sideways I" (see [here](https://www.compart.com/en/unicode/U+A7F7)).

4 years agoRollup merge of #62853 - fakenine:normalize_use_of_backticks_compiler_messages_p13...
Mazdak Farrokhzad [Mon, 22 Jul 2019 13:32:24 +0000 (15:32 +0200)]
Rollup merge of #62853 - fakenine:normalize_use_of_backticks_compiler_messages_p13, r=Centril

normalize use of backticks in compiler messages for librustc/hir

https://github.com/rust-lang/rust/issues/60532

4 years agoRollup merge of #62845 - RalfJung:read, r=rkruppe
Mazdak Farrokhzad [Mon, 22 Jul 2019 13:32:23 +0000 (15:32 +0200)]
Rollup merge of #62845 - RalfJung:read, r=rkruppe

read: fix doc comment

No idea how that happened...

4 years agoRollup merge of #62832 - fakenine:normalize_use_of_backticks_compiler_messages_p12...
Mazdak Farrokhzad [Mon, 22 Jul 2019 13:32:22 +0000 (15:32 +0200)]
Rollup merge of #62832 - fakenine:normalize_use_of_backticks_compiler_messages_p12, r=Centril

normalize use of backticks in compiler messages for librustc_incremental

https://github.com/rust-lang/rust/issues/60532

4 years agoRollup merge of #62812 - fakenine:normalize_use_of_backticks_compiler_messages_p11...
Mazdak Farrokhzad [Mon, 22 Jul 2019 13:32:20 +0000 (15:32 +0200)]
Rollup merge of #62812 - fakenine:normalize_use_of_backticks_compiler_messages_p11, r=GuillaumeGomez

normalize use of backticks in compiler messages for librustc_metadata

https://github.com/rust-lang/rust/issues/60532

4 years agoRollup merge of #62810 - fakenine:normalize_use_of_backticks_compiler_messages_p10...
Mazdak Farrokhzad [Mon, 22 Jul 2019 13:32:18 +0000 (15:32 +0200)]
Rollup merge of #62810 - fakenine:normalize_use_of_backticks_compiler_messages_p10, r=Centril

normalize use of backticks in compiler messages for librustc_lint

https://github.com/rust-lang/rust/issues/60532

4 years agoRollup merge of #62799 - RalfJung:uninit-array, r=Centril
Mazdak Farrokhzad [Mon, 22 Jul 2019 13:32:17 +0000 (15:32 +0200)]
Rollup merge of #62799 - RalfJung:uninit-array, r=Centril

use const array repeat expressions for uninit_array

With a first implementation of https://github.com/rust-lang/rust/issues/49147 having landed, we can make this macro nicer and phase it out with the next bootstrap bump.

However, to make this work, we have to mark `MaybeUninit::uninit()` as promotable. I do feel uneasy about promoting stuff involving uninitialized memory, but OTOH no *operation* on `MaybeUninit` is promotable, so maybe this is okay?

r? @oli-obk @eddyb

4 years agoRollup merge of #62788 - fakenine:normalize_use_of_backticks_compiler_messages_p9...
Mazdak Farrokhzad [Mon, 22 Jul 2019 13:32:15 +0000 (15:32 +0200)]
Rollup merge of #62788 - fakenine:normalize_use_of_backticks_compiler_messages_p9, r=Centril

normalize use of backticks in compiler messages for libcore/ptr

https://github.com/rust-lang/rust/issues/60532

4 years agoRollup merge of #62787 - Indy2222:master, r=Mark-Simulacrum
Mazdak Farrokhzad [Mon, 22 Jul 2019 13:32:14 +0000 (15:32 +0200)]
Rollup merge of #62787 - Indy2222:master, r=Mark-Simulacrum

Fix typo in src/libstd/net/udp.rs doc comment

Affect is usually used as a verb, effect as a verb.

4 years agoadd rustc_private as a proper language feature gate
Aleksey Kladov [Mon, 22 Jul 2019 09:09:34 +0000 (12:09 +0300)]
add rustc_private as a proper language feature gate

At the moment, `rustc_private` as a (library) feature exists by
accident: `char::is_xid_start`, `char::is_xid_continue` methods in
libcore define it.

4 years agoRollup merge of #62746 - RalfJung:deprecated, r=KodrAus
Mazdak Farrokhzad [Mon, 22 Jul 2019 13:32:12 +0000 (15:32 +0200)]
Rollup merge of #62746 - RalfJung:deprecated, r=KodrAus

 do not use assume_init in std::io

Cc https://github.com/rust-lang/rust/issues/62397

4 years agoRollup merge of #62713 - SimonSapin:cast, r=Centril
Mazdak Farrokhzad [Mon, 22 Jul 2019 13:32:11 +0000 (15:32 +0200)]
Rollup merge of #62713 - SimonSapin:cast, r=Centril

Stabilize <*mut _>::cast and <*const _>::cast

Fixes #60602.

FCP: https://github.com/rust-lang/rust/issues/60602#issuecomment-511146402

4 years agoRollup merge of #62709 - nhynes:test-maplike-fromiter, r=cuviper
Mazdak Farrokhzad [Mon, 22 Jul 2019 13:32:09 +0000 (15:32 +0200)]
Rollup merge of #62709 - nhynes:test-maplike-fromiter, r=cuviper

Test that maplike FromIter satisfies uniqueness

This PR adds a simple assertion to the `HashMap` and `HashSet` tests to ensure that uniqueness is satisfied when `FromIter`ing. This is useful for people who want to test their custom type against the Map/Set interfaces since they'll copy the tests wholesale but possibly miss this bug (where _they_ = _me_).

4 years agofix lexing of comments with many \r
Aleksey Kladov [Mon, 22 Jul 2019 09:59:18 +0000 (12:59 +0300)]
fix lexing of comments with many \r

closes #62863

4 years agofix tidy
lqd [Tue, 16 Jul 2019 16:51:13 +0000 (18:51 +0200)]
fix tidy

4 years agoBless output of test nll/loan_ends_mid_block_pair.rs for Polonius, again
lqd [Tue, 16 Jul 2019 15:35:21 +0000 (17:35 +0200)]
Bless output of test nll/loan_ends_mid_block_pair.rs for Polonius, again

Fixing assignments to projections made the Polonius output exactly the same as the NLL one.

4 years agoissue-46589 passes in Polonius and fails in NLL, duplicate it and manually check...
lqd [Tue, 16 Jul 2019 15:34:06 +0000 (17:34 +0200)]
issue-46589 passes in Polonius and fails in NLL, duplicate it and manually check each outcome

4 years agoAdd test to check that assignments to projections do not kill too many loans
lqd [Tue, 16 Jul 2019 15:33:16 +0000 (17:33 +0200)]
Add test to check that assignments to projections do not kill too many loans

4 years agoAdd test checking various assignments are accepted in Polonius
lqd [Tue, 16 Jul 2019 15:32:38 +0000 (17:32 +0200)]
Add test checking various assignments are accepted in Polonius

4 years agoPolonius: generate `killed` facts for assignments to projections
lqd [Tue, 16 Jul 2019 15:30:41 +0000 (17:30 +0200)]
Polonius: generate `killed` facts for assignments to projections

4 years agoBless output of test unboxed-closures/unboxed-closures-failed-recursive-fn-1.rs for...
lqd [Mon, 15 Jul 2019 17:04:50 +0000 (19:04 +0200)]
Bless output of test unboxed-closures/unboxed-closures-failed-recursive-fn-1.rs for Polonius

4 years agoMake both polonius loans tests check-pass
lqd [Mon, 15 Jul 2019 16:57:16 +0000 (18:57 +0200)]
Make both polonius loans tests check-pass

4 years agoRename test so that both "kills-loans" tests match names
lqd [Mon, 15 Jul 2019 16:51:55 +0000 (18:51 +0200)]
Rename test so that both "kills-loans" tests match names

4 years agoAdd test extracted from rand, checking that StorageDead kills loans
lqd [Mon, 15 Jul 2019 16:50:50 +0000 (18:50 +0200)]
Add test extracted from rand, checking that StorageDead kills loans

Like "call-kills-loans", Polonius didn't know about some `killed` facts.