Commit Graph

96509 Commits

Author SHA1 Message Date
Mark Rousskov
f11ffd3a6a
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?
2019-07-23 12:51:18 -04:00
Mark Rousskov
b2155dd747
Rollup merge of #62859 - spastorino:rename-to-as-ref, r=Centril
Place::as_place_ref is now Place::as_ref

r? @oli-obk
2019-07-23 12:51:16 -04:00
Mark Rousskov
4cb3586db9
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
2019-07-23 12:51:15 -04:00
Mark Rousskov
8afc53c195
Rollup merge of #62842 - JohnTitor:test-for-58887, r=alexreg
Add tests for issue-58887

Closes #58887
2019-07-23 12:51:13 -04:00
Mark Rousskov
24a8065c30
Rollup merge of #62817 - estebank:variant-sp, r=matthewjasper
Tweak span for variant not found error
2019-07-23 12:51:12 -04:00
Mark Rousskov
66c2965ac2
Rollup merge of #62808 - crlf0710:gnux32_stack_probe, r=nikic
Revert "Disable stack probing for gnux32."

This reverts commit 42d652ecd6. (#59686)

Closes #59674.
2019-07-23 12:51:10 -04:00
Mark Rousskov
13775d2304
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
2019-07-23 12:51:09 -04:00
Mark Rousskov
ab7149bdc5
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.
2019-07-23 12:51:07 -04:00
Mark Rousskov
4264f8376a
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
2019-07-23 12:51:05 -04:00
Mark Rousskov
ad575978af
Rollup merge of #62523 - pnkfelix:delay-bug-to-resolve-issue-62203-ice, r=varkor
Delay bug to resolve HRTB ICE

Fix #62203
2019-07-23 12:51:04 -04:00
Mark Rousskov
52e9e44c7f
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)
2019-07-23 12:51:02 -04:00
Vadim Petrochenkov
614037171b cleanup: Remove extern crate serialize as rustc_serializes 2019-07-23 19:20:16 +03:00
bors
299ef86e1f Auto merge of #62823 - RalfJung:miri, r=oli-obk
update Miri

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

r? @oli-obk @eddyb
2019-07-23 15:55:26 +00:00
git-iso
f48ee09f04
Update stage0.txt
Fix columns.
2019-07-23 11:07:06 -04:00
Nathan
82dd54baf3 Modify CloudABI ReentrantMutex to use MaybeUninit
Remove uses of mem::uninitialized, which is now deprecated
2019-07-23 10:14:46 -04:00
Saleem Jaffer
3730ed9e5b renames EvalErrorPanic to PanicMessage 2019-07-23 16:42:46 +05:30
bors
3ebca72a11 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
2019-07-23 09:58:48 +00:00
Saleem Jaffer
90426ed642 moving some variants from InterpError to EvalErrorPanic 2019-07-23 13:37:04 +05:30
Aleksey Kladov
7e612c19be
Update src/librustc_lexer/src/lib.rs
Co-Authored-By: Ralf Jung <post@ralfj.de>
2019-07-23 10:38:18 +03:00
git-iso
1ed375c689
Update stage0.txt
Grammar.
2019-07-22 23:30:21 -04:00
Nathan
e1e0df8a49 Remove uses of mem::uninitialized in std::sys::cloudabi
Usages still appear in cloudabi tests and in the reentrant mutex implementation
2019-07-22 20:42:08 -04:00
Alex Touchet
4e02a1f7c5
Change "OSX" to "macOS" 2019-07-22 16:16:59 -07:00
Samy Kacimi
1a7127bbc4
normalize use of backticks in compiler messages for librustc_allocator
https://github.com/rust-lang/rust/issues/60532
2019-07-22 23:30:29 +02:00
bors
e649e90344 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
2019-07-22 17:08:25 +00:00
Brian Cain
4b339688b5 add support for hexagon-unknown-linux-musl 2019-07-22 09:44:58 -05:00
Mazdak Farrokhzad
376382aff3
Rollup merge of #62870 - matklad:issue-62863, r=petrochenkov
fix lexing of comments with many \r

closes #62863
2019-07-22 15:32:29 +02:00
Mazdak Farrokhzad
e178a1e1b3
Rollup merge of #62858 - Rosto75:master, r=jonas-schievink
Change wrong variable name.

r? @steveklabnik
2019-07-22 15:32:27 +02:00
Mazdak Farrokhzad
d75151c546
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)).
2019-07-22 15:32:26 +02:00
Mazdak Farrokhzad
16f585ca1c
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
2019-07-22 15:32:24 +02:00
Mazdak Farrokhzad
b94e59cc41
Rollup merge of #62845 - RalfJung:read, r=rkruppe
read: fix doc comment

No idea how that happened...
2019-07-22 15:32:23 +02:00
Mazdak Farrokhzad
1289677821
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
2019-07-22 15:32:22 +02:00
Mazdak Farrokhzad
063268b2bc
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
2019-07-22 15:32:20 +02:00
Mazdak Farrokhzad
17ddfbe49c
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
2019-07-22 15:32:18 +02:00
Mazdak Farrokhzad
5a20745c96
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
2019-07-22 15:32:17 +02:00
Mazdak Farrokhzad
7dafdd21b1
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
2019-07-22 15:32:15 +02:00
Mazdak Farrokhzad
002f604bc9
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.
2019-07-22 15:32:14 +02:00
Aleksey Kladov
27b703dd40 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.
2019-07-22 16:32:13 +03:00
Mazdak Farrokhzad
1d7faafe47
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
2019-07-22 15:32:12 +02:00
Mazdak Farrokhzad
2567af67a6
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
2019-07-22 15:32:11 +02:00
Mazdak Farrokhzad
0de90c67dc
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_).
2019-07-22 15:32:09 +02:00
Aleksey Kladov
647bf96b79 fix lexing of comments with many \r
closes #62863
2019-07-22 15:39:06 +03:00
lqd
e16bede3f5 fix tidy 2019-07-22 12:46:55 +02:00
lqd
c0eab36bce 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.
2019-07-22 12:46:55 +02:00
lqd
c7f9a71d78 issue-46589 passes in Polonius and fails in NLL, duplicate it and manually check each outcome 2019-07-22 12:46:55 +02:00
lqd
770129c280 Add test to check that assignments to projections do not kill too many loans 2019-07-22 12:46:54 +02:00
lqd
d41e002111 Add test checking various assignments are accepted in Polonius 2019-07-22 12:46:54 +02:00
lqd
2f3e36f51a Polonius: generate killed facts for assignments to projections 2019-07-22 12:46:53 +02:00
lqd
823ab42e66 Bless output of test unboxed-closures/unboxed-closures-failed-recursive-fn-1.rs for Polonius 2019-07-22 11:36:47 +02:00
lqd
9e0fb6fad2 Make both polonius loans tests check-pass 2019-07-22 11:36:46 +02:00
lqd
606f7984e7 Rename test so that both "kills-loans" tests match names 2019-07-22 11:36:46 +02:00