Commit Graph

88790 Commits

Author SHA1 Message Date
Mazdak Farrokhzad
86244854b5
Rollup merge of #57844 - euclio:keyserver-port, r=alexcrichton
use port 80 for retrieving GPG key

This works around firewalls blocking port 11371.

See https://unix.stackexchange.com/questions/75892/keyserver-timed-out-when-trying-to-add-a-gpg-public-key.
2019-01-24 00:20:02 +01:00
Mazdak Farrokhzad
ab998a2eeb
Rollup merge of #57840 - tromey:fix-issue-57762, r=nikic
Fix issue 57762

against a stock LLVM 7.  LLVM 7 was released without a necessary fix
for a bug in the DWARF discriminant code.

This patch changes rustc to use the fallback mode on (non-Rust) LLVM 7.

Closes #57762
2019-01-24 00:20:00 +01:00
Mazdak Farrokhzad
d17f62d857
Rollup merge of #57836 - oli-obk:existential_crisis, r=estebank
Fix some cross crate existential type ICEs

fixes #53443
2019-01-24 00:19:59 +01:00
Mazdak Farrokhzad
5749bac989
Rollup merge of #57834 - SimonSapin:type_id, r=Centril
Stabilize Any::get_type_id and rename to type_id

FCP: https://github.com/rust-lang/rust/issues/27745#issuecomment-373906749

Closes https://github.com/rust-lang/rust/issues/27745.
2019-01-24 00:19:58 +01:00
Mazdak Farrokhzad
b5447b50b0
Rollup merge of #57817 - davidtwco:issue-54521, r=estebank
Add error for trailing angle brackets.

Fixes #54521.

This PR adds a error (and accompanying machine applicable
suggestion) for trailing angle brackets on function calls with a
turbofish.

r? @estebank
2019-01-24 00:19:57 +01:00
Mazdak Farrokhzad
da182a0fe7
Rollup merge of #57795 - estebank:did-you-mean, r=zackmdavis
Use structured suggestion in stead of notes
2019-01-24 00:19:55 +01:00
Mazdak Farrokhzad
8ef8d57029
Rollup merge of #57793 - estebank:impl-trait-resolve, r=oli-obk
Explain type mismatch cause pointing to return type when it is `impl Trait`

Fix #57743.
2019-01-24 00:19:54 +01:00
Mazdak Farrokhzad
2dd63a2e10
Rollup merge of #57779 - estebank:recover-struct-fields, r=davidtwco
Recover from parse errors in literal struct fields and incorrect float literals

Fix #52496.
2019-01-24 00:19:53 +01:00
Mazdak Farrokhzad
b0ec43f569
Rollup merge of #57730 - Zoxc:combined-ast-validator, r=cramertj
Merge visitors in AST validation

Cuts runtime for AST validation on `syntex_syntax` from 31.5 ms to 17 ms.
2019-01-24 00:19:52 +01:00
Mazdak Farrokhzad
e7b584cee1
Rollup merge of #57179 - Xaeroxe:patch-1, r=QuietMisdreavus
Update std/lib.rs docs to reflect Rust 2018 usage

Fixes #56544

This paragraph was written for Rust 2015.  Since 2018 has been stable for a while I think we can update it.
2019-01-24 00:19:50 +01:00
bors
19f8958f82 Auto merge of #57857 - pietroalbini:fix-android-ci, r=aidanhs
Fix Android CI failing to download SDKs

A component of the Android SDK now requires an additional license ([full license text](https://gist.github.com/pietroalbini/28b46a6fed0921d129de58e7aef29f11)) to be accepted before it's possible to use it. The license is dated January 16th 2019, so it's recent.

The weird thing about the license is that it doesn't prompt you to accept it during `sdkmanager --licenses` like all the other ones, but during `sdkmanager platform-tools emulator ...`, and we didn't pipe `yes` to it before this PR.

The PR changes the SDK installation script to accept all the licenses even on the `sdkmanager platform-tools emulator` command.
2019-01-23 15:53:23 +00:00
Oliver Scherer
5d6faf7b4a Remove unused feature gates 2019-01-23 11:34:58 +01:00
Pietro Albini
91f328fb55
make sure to accept all android licenses 2019-01-23 11:21:24 +01:00
bors
6bba352cad Auto merge of #57835 - pnkfelix:issue-57673-remove-leaky-nested-probe, r=arielb1
typeck: remove leaky nested probe during trait object method resolution

addresses #57673  (but not marking with f-x because thats now afflicting beta channel).

Fix #57216
2019-01-22 23:02:38 +00:00
Andy Russell
4e649ccc3a
use port 80 for retrieving GPG key
This works around firewalls blocking port 11371.

See https://unix.stackexchange.com/questions/75892/keyserver-timed-out-when-trying-to-add-a-gpg-public-key.
2019-01-22 16:18:29 -05:00
bors
4c2be9c97f Auto merge of #57805 - matthiaskrgr:rls, r=Xanewok
submodules: update rls and clippy

Changes:
````
Remove state.analysis due to Rust PR #57476
Improve missing nightly readme info
Bump languageserver-types to v0.54.0 and renam crate name to lsp-types
Delete bors.toml
Fix tests
Fix https://github.com/rust-lang/rls/issues/1231
Implement asynchronous message reading
Use typed requests
Implement Tokio-based test LSP client
Update README.md to account for Travis url change
Simplify wait_for_all recv calls
Update dependencies
Revert NLL bug workaround
Remove old test_data entry in .gitignore
Reorganize some tests
Don't test RLS binary target directly
Move tooltip tests to integration tests
Simplify tooltip test harness
Only use FIXTURES_DIR to determine fixtures
Remove src/test/mod.rs
Centralise FIXTURES_DIR across unit and integration tests
Move lens test to tests/
Suppress unused warnings in tests/*
Beautify main.rs and lib.rs
WIP: Move tests
Move src/test/harness to tests/support/harness
Split RLS into bin/lib
Update Clippy
Change all mentions of `rls-preview` to `rls`
Make config mutex borrow scope explicit
Fallback to racer definition
````

Fixes rls build.
2019-01-22 20:04:13 +00:00
Tom Tromey
9452a8dfa3 Simplify the version check
Address the review comments by simplifying the version check to
just "< 8".
2019-01-22 11:45:25 -07:00
Tom Tromey
1c95f5a34c Fix issue 57762
Issue 57762 points out a compiler crash when the compiler was built
using a stock LLVM 7.  LLVM 7 was released without a necessary fix for
a bug in the DWARF discriminant code.

This patch changes rustc to use the fallback mode on (non-Rust) LLVM 7.

Closes #57762
2019-01-22 11:18:01 -07:00
Matthias Krüger
7f8e4aae12 submodules: update clippy from 1838bfe5 to 280069dd
Changes:
````
Rustfmt all the things
Don't make decisions on values that don't represent the decision
Rustup
Actually check for constants.
formatting fix
Update clippy_lints/src/needless_bool.rs
formatting fix
needless bool lint suggestion is wrapped in brackets if it is an "else" clause of an "if-else" statement
Remove negative integer literal checks.
Fix `implicit_return` false positives.
````
2019-01-22 18:03:52 +01:00
Matthias Krüger
696fb8faa9 submodules: update rls from ae0d89a to c9d25b6
Changes:
````
Remove state.analysis due to Rust PR #57476
Improve missing nightly readme info
Bump languageserver-types to v0.54.0 and renam crate name to lsp-types
Delete bors.toml
Fix tests
Fix https://github.com/rust-lang/rls/issues/1231
Implement asynchronous message reading
Use typed requests
Implement Tokio-based test LSP client
Update README.md to account for Travis url change
Simplify wait_for_all recv calls
Update dependencies
Revert NLL bug workaround
Remove old test_data entry in .gitignore
Reorganize some tests
Don't test RLS binary target directly
Move tooltip tests to integration tests
Simplify tooltip test harness
Only use FIXTURES_DIR to determine fixtures
Remove src/test/mod.rs
Centralise FIXTURES_DIR across unit and integration tests
Move lens test to tests/
Suppress unused warnings in tests/*
Beautify main.rs and lib.rs
WIP: Move tests
Move src/test/harness to tests/support/harness
Split RLS into bin/lib
Update Clippy
Change all mentions of `rls-preview` to `rls`
Make config mutex borrow scope explicit
Fallback to racer definition
````

Fixes rls build.
2019-01-22 18:03:52 +01:00
Jacob Kiesel
4781c6f8e7
Remove unused links 2019-01-22 09:39:19 -07:00
bors
96909179d9 Auto merge of #57647 - cuviper:gdb-version, r=tromey
[rust-gdb] relax the GDB version regex

The pretty-printer script is checking `gdb.VERSION` to see if it's at
least 8.1 for some features. With `re.match`, it will only find the
version at the beginning of that string, but in Fedora the string is
something like "Fedora 8.2-5.fc29". Using `re.search` instead will find
the first location that matches anywhere, so it will find my 8.2.
2019-01-22 16:14:42 +00:00
Oliver Scherer
26edb28d31 Fix some cross crate existential type ICEs 2019-01-22 16:08:00 +01:00
Felix S. Klock II
33c2ceb3a2 unit test for issue 57673. 2019-01-22 14:49:18 +01:00
Felix S. Klock II
2dea8ec630 Do not initiate nested probe within assemble_probe.
In particular, the table entries (associated with type-variables
created during the probe) must persist as long as the candidates
assembled during the probe. If you make a nested probe without
creating a nested `ProbeContext`, the table entries are popped at the
end of the nested probe, while the type-variables would leak out via
the assembled candidates attached to `self` (the outer
`ProbeContext`). This causes an ICE (*if you are lucky*)!
2019-01-22 14:45:13 +01:00
bors
ad30e9a681 Auto merge of #57830 - Centril:rollup, r=Centril
Rollup of 9 pull requests

Successful merges:

 - #57537 (Small perf improvement for fmt)
 - #57552 (Default images)
 - #57604 (Make `str` indexing generic on `SliceIndex`.)
 - #57667 (Fix memory leak in P::filter_map)
 - #57677 (const_eval: Predetermine the layout of all locals when pushing a stack frame)
 - #57791 (Add regression test for #54582)
 - #57798 (Corrected spelling inconsistency)
 - #57809 (Add powerpc64-unknown-freebsd)
 - #57813 (fix validation range printing when encountering undef)

Failed merges:

r? @ghost
2019-01-22 13:40:01 +00:00
Simon Sapin
fb5d3c1f37 Stabilize Any::get_type_id and rename to type_id
FCP: https://github.com/rust-lang/rust/issues/27745#issuecomment-373906749
2019-01-22 14:25:27 +01:00
Mazdak Farrokhzad
dec7b7b131
Rollup merge of #57813 - RalfJung:validation-range-printing, r=oli-obk
fix validation range printing when encountering undef
2019-01-22 12:20:36 +01:00
Mazdak Farrokhzad
e3849cc8c9
Rollup merge of #57809 - MikaelUrankar:powerpc64-unknown-freebsd, r=nagisa
Add powerpc64-unknown-freebsd

FreeBSD review: https://reviews.freebsd.org/D18367
2019-01-22 12:20:34 +01:00
Mazdak Farrokhzad
8c551155d9
Rollup merge of #57798 - hellow554:master, r=davidtwco
Corrected spelling inconsistency

resolves #57773
2019-01-22 12:20:33 +01:00
Mazdak Farrokhzad
892e6930ce
Rollup merge of #57791 - estebank:issue-54582, r=zackmdavis
Add regression test for #54582

Fix #54582.
2019-01-22 12:20:32 +01:00
Mazdak Farrokhzad
973e754fc4
Rollup merge of #57677 - dotdash:locals, r=michaelwoerister
const_eval: Predetermine the layout of all locals when pushing a stack frame

Usually the layout of any locals is required at least three times, once
when it becomes live, once when it is written to, and once it is read
from. By adding a cache for them, we can reduce the number of layout
queries speeding up code that is heavy on const_eval.
2019-01-22 12:20:31 +01:00
Mazdak Farrokhzad
7fb44e8604
Rollup merge of #57667 - ishitatsuyuki:p-leak, r=nnethercote
Fix memory leak in P::filter_map

Probably this function isn't widely used, but anyway this wasn't working as intended.

r? @eddyb

Do not rollup if you want to see if max-rss change in perf.
2019-01-22 12:20:29 +01:00
Mazdak Farrokhzad
ad55b73da1
Rollup merge of #57604 - alercah:str-index, r=sfackler
Make `str` indexing generic on `SliceIndex`.

Fixes #55603
2019-01-22 12:20:28 +01:00
Mazdak Farrokhzad
e3d3cff019
Rollup merge of #57552 - GuillaumeGomez:default-images, r=QuietMisdreavus
Default images

Add default rust logo (the image at the top of the sidebar) and default favicon. No more missing image or inexistent icon on the documentation tabs!

r? @QuietMisdreavus
2019-01-22 12:20:27 +01:00
Mazdak Farrokhzad
e437861d27
Rollup merge of #57537 - sinkuu:fmt_perf, r=alexcrichton
Small perf improvement for fmt

Added benchmark is based on #10761
2019-01-22 12:20:23 +01:00
bors
76c87a166f Auto merge of #56221 - estebank:remove-dummy-checks, r=varkor
Remove unnecessary dummy span checks

The emitter already verifies wether a given span note or span label
can be emitted to the output. If it can't, because it is a dummy
span, it will be either elided for labels or emitted as an unspanned
note/help when applicable.
2019-01-22 10:59:09 +00:00
bors
70015373b4 Auto merge of #57821 - RalfJung:miri, r=oli-obk
update miri

r? @oli-obk
2019-01-22 08:24:58 +00:00
Marcel Hellwig
051835b903 Corrected spelling inconsistency
resolves #57773
2019-01-22 09:08:52 +01:00
bors
8e9774ffcf Auto merge of #57475 - SimonSapin:signed, r=estebank
Add signed num::NonZeroI* types

Multiple people have asked for them in https://github.com/rust-lang/rust/issues/49137. Given that the unsigned ones already exist, they are very easy to add and not an additional maintenance burden.
2019-01-22 05:42:11 +00:00
varkor
f077990ed4
Fix typo
Co-Authored-By: estebank <estebank@users.noreply.github.com>
2019-01-21 15:53:56 -08:00
varkor
1d6e5e7108
Fix typo
Co-Authored-By: estebank <estebank@users.noreply.github.com>
2019-01-21 15:53:45 -08:00
Esteban Küber
4745b86202 Accept more invalid code that is close to correct fields 2019-01-21 15:47:23 -08:00
David Wood
914d142c02
Extend trailing > detection for paths.
This commit extends the trailing `>` detection to also work for paths
such as `Foo::<Bar>>:Baz`.

This involves making the existing check take the token that is expected
to follow the path being checked as a parameter.

Care is taken to ensure that this only happens on the construction of a
whole path segment and not a partial path segment (during recursion).

Through this enhancement, it was also observed that the ordering of
right shift token and greater than tokens was overfitted to the examples
being tested.

In practice, given a sequence of `>` characters: `>>>>>>>>>`
..then they will be split into `>>` eagerly: `>> >> >> >> >`.
..but when a `<` is prepended, then the first `>>` is split:
`<T> > >> >> >> >`
..and then when another `<` is prepended, a right shift is first again:
`Vec<<T>> >> >> >> >`

In the previous commits, a example that had two `<<` characters was
always used and therefore it was incorrectly assumed that `>>` would
always be first - but when there is a single `<`, this is not the case.
2019-01-22 00:35:31 +01:00
Esteban Küber
ab2479b00d Move logic to its own method 2019-01-21 15:13:59 -08:00
bors
51cc3cdcf0 Auto merge of #55009 - oli-obk:const_safety, r=RalfJung
Make raw ptr ops unsafe in const contexts

r? @RalfJung

cc @Centril
2019-01-21 23:10:11 +00:00
David Wood
3f0fc9b035
Pluralize error messages.
This commit pluralizes error messages when more than a single trailing
`>` character is present.
2019-01-21 22:42:54 +01:00
David Wood
6c399d155c
Add error for trailing angle brackets.
This commit adds a error (and accompanying machine applicable
suggestion) for trailing angle brackets on function calls with a
turbofish.
2019-01-21 22:42:54 +01:00
Ralf Jung
2aa52035d5 update miri 2019-01-21 22:25:02 +01:00
Ralf Jung
400e28d27a fix validation range printing when encountering undef 2019-01-21 19:08:47 +01:00