Commit Graph

75021 Commits

Author SHA1 Message Date
Dale Wijnand
e3e1c8f7d2
Fix capitalisation in Path#file_name's docs 2018-02-24 12:31:03 +00:00
bors
6070d3e47e Auto merge of #48476 - Manishearth:rollup, r=Manishearth
Rollup of 12 pull requests

- Successful merges: #47933, #48072, #48083, #48123, #48157, #48219, #48221, #48245, #48429, #48436, #48438, #48472
- Failed merges:
2018-02-24 07:55:34 +00:00
Bryan Drewery
34b45c192f Workaround abort(2) on compilation error on FreeBSD.
Same problem as OpenBSD, tracking bug #43575.
2018-02-23 19:36:32 -08:00
bors
b0a8620ed6 Auto merge of #48487 - Mark-Simulacrum:appveyor-split, r=Mark-Simulacrum
Split MinGW tests into two builders on AppVeyor

Run-pass and compile-fail tests appear to take the most significant chunk of time, so split them into their own builder.

Should help with https://github.com/rust-lang/rust/issues/46903.

r? @kennytm
cc @alexcrichton
2018-02-24 00:54:15 +00:00
Guillaume Gomez
23dc694c42 Fix auto trait impl rustdoc ice 2018-02-24 01:23:54 +01:00
John Paul Adrian Glaubitz
e3781c6585 test: Fix s390x-unknown-linux-gnu atomic-lock-free test not run for systemz 2018-02-24 01:18:33 +01:00
Vadim Petrochenkov
8640a51ff8 Implement multiple patterns with | in if let and while let 2018-02-24 03:12:35 +03:00
John Paul Adrian Glaubitz
0b6583ed97 bootstrap: Add openssl configuration for x86_64-unknown-linux-gnux32 2018-02-24 01:08:02 +01:00
varkor
70db41cdf7 Handle gdb command failure gracefully in compiletest
Previously, if the gdb command was available, but threw an error, compiletest would panic.  This is obviously not good. Now, gdb is treated as missing if calling `gdb --version` does not output anything on stdout.
2018-02-23 23:54:24 +00:00
Mark Simulacrum
91fbefa594 Split MinGW tests into two builders on AppVeyor
Run-pass and compile-fail tests appear to take the most significant
chunk of time, so split them into their own builder.
2018-02-23 16:19:17 -07:00
varkor
f2b9686134 Bad tags are unreachable 2018-02-23 22:15:07 +00:00
Manish Goregaokar
4c73f82614 Add test 2018-02-23 13:30:26 -08:00
Manish Goregaokar
dd67fe1727 Silence warning in test 2018-02-23 13:00:11 -08:00
Manish Goregaokar
bdccbcf41b parse dyn (Foo) as a trait object 2018-02-23 12:39:51 -08:00
Mark Mansi
a05c5538d4 Start moving to the rustc guide! 2018-02-23 13:20:56 -06:00
Manish Goregaokar
b26442a3cb
Rollup merge of #48472 - Manishearth:clippyup, r=oli-obk
Update clippy

r? @oli-obk
2018-02-23 10:24:57 -08:00
Manish Goregaokar
f2cbb764b8
Rollup merge of #48438 - mbrubeck:docs, r=TimNN
[docs] Minor wording changes to drain_filter docs

The docs currently say, "If the closure returns false, it will try again, and call the closure on the next element."  But this happens regardless of whether the closure returns true or false.
2018-02-23 10:24:56 -08:00
Manish Goregaokar
cf3623f284
Rollup merge of #48436 - adeschamps:string-doc-fix, r=estebank
Small grammar fix to docs for String::new()
2018-02-23 10:24:55 -08:00
Manish Goregaokar
f2da2fa315
Rollup merge of #48429 - toidiu:patch-1, r=nikomatsakis
update tracking issue for nll

Point to the new tracing issue for nll

For reference https://github.com/rust-lang/rust/issues/44928
2018-02-23 10:24:54 -08:00
Manish Goregaokar
74f6794193
Rollup merge of #48245 - spastorino:sparse_bitsets, r=nikomatsakis
Use sparse bitsets instead of dense ones for NLL results

This is for https://github.com/rust-lang/rust/issues/48170.

r? @nikomatsakis
2018-02-23 10:24:53 -08:00
Manish Goregaokar
9f36a35e61
Rollup merge of #48221 - rkruppe:improve-ctypes-lint, r=estebank
Overhaul improper_ctypes output

This snowballed into a rather big set of improvements to the diagnostics of the improper_ctypes lint. See commits for details, including effects of each change on the `compile-fail/improper-ctypes.rs` test (now a UI test), which is pretty gnarly and hopefully not representative of real code, but covers a lot of different error cases.

Fixes #42050
2018-02-23 10:24:52 -08:00
Manish Goregaokar
5d30cbab8e
Rollup merge of #48219 - andjo403:export_symbol, r=michaelwoerister
lookup exported symbols only when needed.

reduces the time to compile small file with no optimization by half.
2018-02-23 10:24:51 -08:00
Manish Goregaokar
5fd8d18097
Rollup merge of #48157 - scottmcm:try-for-each, r=dtolnay
Add Iterator::try_for_each

The fallible version of `for_each` aka the stateless version of `try_fold`.  Inspired by @cuviper's comment in https://github.com/rust-lang/rust/pull/45379#issuecomment-338370020 as a more direct and obvious solution than `.map(f).collect::<Result<(), _>>()`.

Like `for_each`, no need for an `r` version thanks to overrides in `Rev`.

`iterator_try_fold` tracking issue: https://github.com/rust-lang/rust/issues/45594
2018-02-23 10:24:49 -08:00
Manish Goregaokar
1e67c1315b
Rollup merge of #48123 - nikomatsakis:issue-47244-expected-num-args, r=estebank
detect wrong number of args when type-checking a closure

Instead of creating inference variables for those argument types, use
the trait error-reporting code to give a nicer error. This also
improves some other spans for existing tests.

Fixes #47244

r? @estebank
2018-02-23 10:24:48 -08:00
Manish Goregaokar
a1acb15591
Rollup merge of #48083 - jseyfried:improve_tuple_struct_field_access_hygiene, r=petrochenkov
Improve tuple struct field access hygiene

Fixes #47312 by fixing a span bug.
r? @nrc
2018-02-23 10:24:47 -08:00
Manish Goregaokar
4941cb4796
Rollup merge of #48072 - cramertj:impl-trait-lifetime-res, r=nikomatsakis
Fix nested impl trait lifetimes

Fixes #46464
cc https://github.com/rust-lang/rust/issues/34511

r? @nikomatsakis
2018-02-23 10:24:46 -08:00
Manish Goregaokar
abf4d70da8
Rollup merge of #47933 - Zoxc:plugin-panics, r=nikomatsakis
Do not run the default panic hook inside procedural macros.

Fixes #47812

r? @nikomatsakis
2018-02-23 10:24:45 -08:00
Pietro Albini
2985a1abfb
Report non-standard compile flags on ICE 2018-02-23 18:58:14 +01:00
John Paul Adrian Glaubitz
84aae4ed12 Add sparc-unknown-linux-gnu target 2018-02-23 18:21:00 +01:00
John Paul Adrian Glaubitz
100469f4e9 librustc_back: Add support for sparc-linux-gnu 2018-02-23 18:20:56 +01:00
Manish Goregaokar
9e6d2d761e Update Clippy 2018-02-23 09:04:16 -08:00
kennytm
a9f940e320
Run the external doc tests in tools job. 2018-02-24 00:54:13 +08:00
Manish Goregaokar
177271f914 span_bug doesn't work well at this stage, use the session directly 2018-02-23 08:24:49 -08:00
Manish Goregaokar
63168f7275 Lint bare traits 2018-02-23 08:24:49 -08:00
Manish Goregaokar
bd29696218 Add ability for hardwired lints to operate on the diagnostic builder 2018-02-23 08:24:49 -08:00
Manish Goregaokar
3eeabe7b7d Add hardwired lint for dyn trait 2018-02-23 08:24:07 -08:00
Manish Goregaokar
da9dc0507b Allow future-incompat lints to mention an epoch 2018-02-23 08:24:07 -08:00
Niko Matsakis
bcd996857e explain why we don't need to run type-checker when NLL is enabled 2018-02-23 10:42:12 -05:00
Niko Matsakis
2370b60529 update tests and reference files
The type checker invokes the borrow checker for closures it finds, so
removing the NLL type checker affects ordering of errors somewhat.
2018-02-23 10:40:57 -05:00
Niko Matsakis
380e388a86 do not run MIR type checker twice 2018-02-23 10:36:56 -05:00
Niko Matsakis
10f7c11092 re-export assert_test_result for use when testing libtest itself 2018-02-23 10:11:06 -05:00
Seo Sanghyeon
8e4ad29cb9 Disable NEON on musl ARMv7 2018-02-23 21:48:41 +09:00
Niko Matsakis
068e3832cd update test -- we now give a slightly different error 2018-02-23 07:34:00 -05:00
bors
063deba92e Auto merge of #47799 - topecongiro:fix-span-of-visibility, r=petrochenkov
Fix span of visibility

This PR

1. adds a closing parenthesis to the span of `Visibility::Crate` (e.g. `pub(crate)`). The current span only covers `pub(crate`.
2. adds a `span` field to `Visibility::Restricted`. This span covers the entire visibility expression (e.g. `pub (in self)`). Currently all we can have is a span for `Path`.

This PR is motivated by the bug found in rustfmt (https://github.com/rust-lang-nursery/rustfmt/issues/2398).

The first change is a strict improvement IMHO. The second change may not be desirable, as it adds a field which is currently not used by the compiler.
2018-02-23 11:21:29 +00:00
John Paul Adrian Glaubitz
871e82e7a4 bootstrap: Add openssl configuration for sparc-unknown-linux-gnu 2018-02-23 11:20:23 +01:00
John Paul Adrian Glaubitz
a895d438c2 bootstrap: Add missing cputype matching for sparc 2018-02-23 11:18:29 +01:00
bors
928435305a Auto merge of #48052 - eddyb:deggregate, r=nikomatsakis
rustc_mir: handle all aggregate kinds in, and always run, the deaggregator.

This helps with removing`Rvalue::Aggregate` from the MIR, and with enabling more optimizations.
r? @nikomatsakis
2018-02-23 02:21:06 +00:00
Niko Matsakis
0a5f4aebb1 move test to the proper directory and test #[bench] 2018-02-22 20:16:30 -05:00
Niko Matsakis
a0562ec369 delete this test file: it also appears as
src/rfc-1937-termination-trait/termination-trait-for-result-box-error_ok.rs
2018-02-22 20:16:06 -05:00
varkor
8b2037c6fe Introduce UnpackedKind
This adds an `UnpackedKind` type as a typesafe counterpart to `Kind`. This should make future changes to kinds (such as const generics!) more resilient, as the type-checker should catch more potential issues.
2018-02-23 01:13:54 +00:00