Commit graph

139135 commits

Author SHA1 Message Date
Cameron Steffen
4ac14f9e63 Teach SpanlessEq binding IDs 2021-02-17 10:47:26 -06:00
bors
5ef21063f0 Auto merge of #82116 - tmiasko:box-error, r=oli-obk
Reduce size of InterpErrorInfo to 8 bytes

r? `@ghost`
2021-02-17 16:47:18 +00:00
Ryan Levick
2a66685ebf Make sure pdbs are copied along with exe and dlls when bootstrapping 2021-02-17 15:56:48 +01:00
hyd-dev
43aed7441e
[libtest] Run the test synchronously when hitting thread limit 2021-02-17 21:38:25 +08:00
bors
ddeea97714 Auto merge of #6750 - flip1995:lintcheck_options, r=matthiaskrgr
Lintcheck and an options for command line options

Make it possible to add command line options to the clippy invocation of the lintcheck-tool

changelog: none

r? `@matthiaskrgr`

I found that this will be really helpful if we use a separate repository and want to maintain a all-lints-passing list of crates. See my early experimentation here: https://github.com/flip1995/clippy-lintcheck

```
git submodule update --init
cargo run -- --mode=all
```

Will run the lintcheck tool on all the specified crates in `config/` in that repository.
2021-02-17 12:53:31 +00:00
Takayuki Maeda
2d60a6113d replace if-let and while-let with if let and while let 2021-02-17 19:26:38 +09:00
Takayuki Maeda
0f04875d2e replace if-let and while-let with if let and while let 2021-02-17 19:26:38 +09:00
est31
003670748f Remove redundant to_string calls 2021-02-17 11:25:55 +01:00
Mara Bos
ad93f48d77 Add comment about how we find the right span in non_fmt_panic. 2021-02-17 10:51:22 +01:00
est31
c5b9264929 Replace vec![] calls with slice literals
There is no need to create vec's here
2021-02-17 10:37:47 +01:00
bjorn3
4fa9e08e3d Enable the tests on Arm Linux too 2021-02-17 10:01:39 +01:00
Guillaume Gomez
fcf6e6e80d Add check for ES5 in CI 2021-02-17 09:53:33 +01:00
est31
6460205031 Remove redundant rustc_data_structures path component 2021-02-17 09:30:08 +01:00
flip1995
79d7f4ccb3
lintcheck: Add a note that -Wclippy::all is enabled by default 2021-02-17 08:35:57 +01:00
Henry Boisdequin
e13f25cd66 make suggest setup help messages better 2021-02-17 12:26:02 +05:30
bors
ee88f46bb5 Auto merge of #82197 - tmiasko:try-get-cached, r=cjgillot
Inline try_get_cached
2021-02-17 04:07:35 +00:00
Eric Huss
ee0e841a2e rustdoc: treat edition 2021 as unstable 2021-02-16 19:17:01 -08:00
Joshua Nelson
2bc5a0a600 Make Clean take &mut DocContext
- Take `FnMut` in `rustc_trait_selection::find_auto_trait_generics`
- Take `&mut DocContext` in most of `clean`
- Collect the iterator in auto_trait_impls instead of iterating lazily; the lifetimes were really bad.
- Changes `fn sess` to properly return a borrow with the lifetime of `'tcx`, not the mutable borrow.
2021-02-16 21:25:14 -05:00
Joshua Nelson
6da9e3c226 Take &mut DocContext in passes
This should hopefully allow for less interior mutability.
2021-02-16 20:58:38 -05:00
Eric Huss
5715f79b37 Update books 2021-02-16 17:19:28 -08:00
Khem Raj
8b38a5020f Add riscv32 and riscv64 musl to supported platform targets
Signed-off-by: Khem Raj <raj.khem@gmail.com>
2021-02-16 16:44:39 -08:00
Khem Raj
f049e27354 add specs for riscv32/riscv64 musl targets
Signed-off-by: Khem Raj <raj.khem@gmail.com>
2021-02-16 16:34:32 -08:00
Caio
e7e93717ce Move some tests to more reasonable directories 2021-02-16 21:22:21 -03:00
Teddy Katz
15197cbc61 Ensure debug_assert! tests get run 2021-02-16 19:05:30 -05:00
Tomasz Miąsko
614b0cccfe Use -Ccodegen-units=1 to make issue-23458 test deterministic
The test case fails with either one error or two errors.
Use a single code generation unit to avoid nondeterminism.
2021-02-17 00:00:00 +00:00
Tomasz Miąsko
e190f0d974 Reduce size of InterpErrorInfo to 8 bytes 2021-02-17 08:57:06 +01:00
Tomasz Miąsko
f2da425bff ./x.py fmt 2021-02-16 23:52:05 +01:00
Tomasz Miąsko
d06a2a368d Pass MPlaceTy by reference not value 2021-02-16 23:52:05 +01:00
Tomasz Miąsko
5888556efe Pass ImmTy by reference not value 2021-02-16 23:52:05 +01:00
Tomasz Miąsko
fe0c46d07e Pass PlaceTy by reference not value 2021-02-16 23:52:05 +01:00
Tomasz Miąsko
e915cf45dc Pass OpTy by reference not value 2021-02-16 23:52:05 +01:00
Tomasz Miąsko
6c9d7fbeed Add size assertions for interpreter data structures 2021-02-16 23:34:50 +01:00
bors
8fe989dd76 Auto merge of #81611 - cjgillot:meowner, r=estebank
Only store a LocalDefId in some HIR nodes

Some HIR nodes are guaranteed to be HIR owners: Item, TraitItem, ImplItem, ForeignItem and MacroDef.
As a consequence, we do not need to store the `HirId`'s `local_id`, and we can directly store a `LocalDefId`.

This allows to avoid a bit of the dance with `tcx.hir().local_def_id` and `tcx.hir().local_def_id_to_hir_id` mappings.
2021-02-16 22:14:32 +00:00
Giacomo Stevanato
61bb1836f8 Optimize Iterator::is_sorted_by by using Iterator::all for internal iteration 2021-02-16 21:49:56 +01:00
Ryan Levick
5b0ed02bb9 Delete symlinked directories 2021-02-16 21:19:53 +01:00
Manish Goregaokar
a98b22c837 Add caveat to Path::display() about lossiness 2021-02-16 11:45:46 -08:00
bors
a143517d44 Auto merge of #82192 - GuillaumeGomez:rollup-gi1639b, r=GuillaumeGomez
Rollup of 6 pull requests

Successful merges:

 - #82145 (Fix ES5 errors (IE11))
 - #82160 (Fix typo in rustc_infer::infer::UndoLog)
 - #82161 (Add long explanation for E0545)
 - #82163 (avoid full-slicing slices)
 - #82175 (validation: fix invalid-fn-ptr error message)
 - #82184 ([Minor] Update discriminant_value docs)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
2021-02-16 19:21:22 +00:00
kadmin
f52029553f Remove ordering hint 2021-02-16 19:04:03 +00:00
Guillaume Gomez
9502e5c4dc
Rollup merge of #82184 - petertodd:2021-discriminant-value-doc, r=nagisa
[Minor] Update discriminant_value docs

Updated for new `DiscriminantKind` trait.
2021-02-16 19:21:21 +01:00
Guillaume Gomez
866dc5aae5
Rollup merge of #82175 - RalfJung:invalid-fn-ptr, r=oli-obk
validation: fix invalid-fn-ptr error message

https://github.com/rust-lang/rust/pull/82061 changed the code here to print an `ImmTy` instead of a `ScalarMaybeUninit`; that was an accident. So go back to printing a `ScalarMaybeUninit`.

r? ```@oli-obk```
2021-02-16 19:21:21 +01:00
Guillaume Gomez
46b93b2e44
Rollup merge of #82163 - matthiaskrgr:slice, r=jyn514
avoid full-slicing slices

If we already have a slice, there is no need to get another full-range slice from that, just use the original.
clippy::redundant_slicing
2021-02-16 19:21:20 +01:00
Guillaume Gomez
cdab137bd4
Rollup merge of #82161 - jesusprubio:add-long-explanation-e0545, r=GuillaumeGomez
Add long explanation for E0545

Helps with #61137
2021-02-16 19:21:19 +01:00
Guillaume Gomez
73d6b603a7
Rollup merge of #82160 - pierwill:patch-2, r=lcnr
Fix typo in rustc_infer::infer::UndoLog

Also use double quotes.
2021-02-16 19:21:18 +01:00
Guillaume Gomez
4df040176d
Rollup merge of #82145 - GuillaumeGomez:es5-checks, r=Nemo157
Fix ES5 errors (IE11)

rustdoc is supposed to run on IE11 but someone reported me that it wasn't. I just confirmed it by using `es-check` with the `es5` option like this:

```
$ es-check es5 src/librustdoc/html/static/*.js
```

The PR fixes those issues and add CI checks to prevent regressions.

`@Mark-Simulacrum:` I added checks in the CI, but not sure if it's the correct way to do it. Any help on that side would be very appreciated!

r? `@Nemo157`
2021-02-16 19:21:14 +01:00
flip1995
e3f584665a
Reformat clippy_dev README 2021-02-16 18:09:34 +01:00
bors
877be189ad Auto merge of #6749 - camsteffen:test-all, r=Manishearth
Test workspace at once

changelog: none

Follow-up to #6733
2021-02-16 17:03:03 +00:00
Cameron Steffen
e355652fec Test workspace at once 2021-02-16 10:50:43 -06:00
bors
9d3deed8a2 Auto merge of #82150 - RalfJung:miri, r=RalfJung
update Miri

This pulls in the recent cargo-miri fixes by `@hyd-dev.`
Cc `@rust-lang/miri` r? `@ghost`
Fixes https://github.com/rust-lang/rust/issues/82173
2021-02-16 16:22:56 +00:00
Cameron Steffen
9bcb257985 Add workspace to manifest 2021-02-16 10:14:40 -06:00
flip1995
dd5c9b7dda
lintcheck: Slight improvements to the error reporting 2021-02-16 16:58:00 +01:00