kennytm
abf4d8babf
When picking a candidate, consider the unstable ones last.
...
If there is potential ambiguity after stabilizing those candidates, a
warning will be emitted.
2018-03-24 06:58:01 +08:00
Andrew Cann
59688e119e
Make coerce_never lint an error
...
Remove the coerce_never lint and make the behaviour an error.
2018-03-14 12:44:51 +08:00
Andrew Cann
9b15ddb29e
remove defaulting to unit
...
Types will no longer default to `()`, instead always defaulting to `!`.
This disables the associated warning and removes the flag from TyTuple
2018-03-14 12:44:51 +08:00
Manish Goregaokar
197f35c3e0
Make bare_trait_lint allow for now
2018-03-08 17:10:05 -08:00
Manish Goregaokar
4338bd178d
Move epochs to libsyntax
2018-03-08 17:10:03 -08:00
Oliver Schneider
28572d2c1f
Nuke the entire ctfe from orbit, it's the only way to be sure
2018-03-08 08:08:14 +01:00
Manish Goregaokar
0cb367266b
Emit parentheses in suggestion for global paths
2018-02-27 19:24:16 -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
dpc
accd997b54
add ellided lifetime
2018-02-02 02:10:10 +05:30
Carol (Nichols || Goulding)
90fcd4476c
Reexport -> re-export in error messages
2018-01-15 13:36:52 -05:00
Michael Hewson
0783db9e0f
Convert warning about *const _
to a future-compat lint
2017-12-22 07:05:09 -05:00
Niko Matsakis
e741dad629
adding lint for single use lifetime names
2017-12-20 00:07:10 +05:30
Ariel Ben-Yehuda
425c2c3606
convert errors to warnings
2017-12-06 00:43:47 +02:00
Ariel Ben-Yehuda
2614cc51dd
convert the new conflicts to a soft error
2017-12-05 15:42:33 +02:00
Ariel Ben-Yehuda
5a00b7cb74
make coercions to !
in unreachable code a hard error
...
This was added to cover up a lazy extra semicolon in #35849 , but does
not actually make sense. This is removed as a part of the stabilization
of `never_type`.
2017-11-30 15:18:25 +02:00
Ariel Ben-Yehuda
1a2d443f55
make accessing packed fields a future-compat warning
2017-11-26 16:12:42 +02:00
Niko Matsakis
0d78e40e88
convert EXTRA_REQUIREMENT_IN_IMPL into a hard error
...
cc #37166
2017-11-15 16:49:21 -05:00
Vadim Petrochenkov
bf0cdb52f2
Add several lints into unused
lint group
...
Remove a couple of obsolete lints
2017-10-29 22:14:23 +03:00
Alex Crichton
4df1278c69
rustc: Remove used_mut_nodes
from TyCtxt
...
This updates the borrowck query to return a result, and this result is then used
to incrementally check for unused mutable nodes given sets of all the used
mutable nodes.
Closes #42384
2017-10-14 09:29:02 -07:00
David Tolnay
247b58b4f4
Allow unused extern crate again
...
This is a partial revert of #42588 . There is a usability concern
reported in #44294 that was not considered in the discussion of the PR,
so I would like to back this out of 1.21. As is, I think users would
have a worse and more confusing experience with this lint enabled by
default. We can re-enabled once there are better diagnostics or the case
in #44294 does not trigger the lint.
2017-09-24 23:57:45 -07:00
Alex Crichton
058202e523
rustc: Remove the used_unsafe
field on TyCtxt
...
Now that lint levels are available for the entire compilation, this can be an
entirely local lint in `effect.rs`
2017-08-30 16:09:02 -07:00
Tatsuyuki Ishi
bc5bd51c45
Make unused-extern-crate warn-by-default
2017-08-27 19:02:24 +09:00
Vadim Petrochenkov
39114f9169
Make late_bound_lifetime_arguments
lint warn-by-default
2017-07-18 00:33:44 +03:00
Vadim Petrochenkov
7ca378b251
Prohibit lifetime arguments in path segments with late bound lifetime parameters
2017-07-18 00:12:48 +03:00
Vadim Petrochenkov
9196f874e4
Make patterns_in_fns_without_body
warn-by-default again
...
Fix some tests on Linux
2017-07-08 03:01:11 +03:00
Vadim Petrochenkov
bdffb9722d
Move public reexports of private extern crates into a separate lint
...
This is going to be a hard error while all private-in-public errors from rustc_privacy will be reclassified into lints.
2017-07-08 01:56:27 +03:00
Vadim Petrochenkov
96bcdac9e4
Make sufficiently old or low-impact compatibility lints deny-by-default
2017-07-08 01:56:27 +03:00
Vadim Petrochenkov
26d5c0e20c
Turn invalid_type_param_default
into a lint again
2017-05-30 22:00:30 +03:00
Vadim Petrochenkov
caecb76f08
Turn sufficiently old compatibility lints into hard errors
2017-05-30 22:00:30 +03:00
bors
03bed65514
Auto merge of #41856 - qnighy:prohibit-parenthesized-params-in-more-types, r=arielb1
...
Prohibit parenthesized params in more types.
Prohibit parenthesized parameters in primitive types, type parameters, `Self`, etc.
Fixes #32995 .
2017-05-29 11:32:14 +00:00
Masaki Hara
99993780dc
Add warning cycle #42238 .
2017-05-26 22:21:46 +09:00
est31
df188b8f97
Add lint for unused macros
2017-05-13 16:02:29 +02:00
bors
691eba1358
Auto merge of #34198 - eddyb:you're-a-bad-transmute-and-you-should-feel-bad, r=nikomatsakis
...
Make transmuting from fn item types to pointer-sized types a hard error.
Closes #19925 by removing the future compatibility lint and the associated workarounds.
This is a `[breaking-change]` if you `transmute` from a function item without casting first.
For more information on how to fix your code, see https://github.com/rust-lang/rust/issues/19925 .
2017-03-01 10:03:44 +00:00
Jeffrey Seyfried
61a9a14d29
Add warning cycle.
2017-02-28 22:15:12 +00:00
Eduard Burtescu
7650afc1ce
Make transmuting from fn item types to pointer-sized types a hard error.
2017-02-28 23:47:55 +02:00
Andrew Cann
5c90dd7978
Use a proper future-compatibility lint
2017-02-03 18:48:15 +08:00
Vadim Petrochenkov
8b060e25ba
Implement compatibility lint for legacy constructor visibilities
2017-01-29 02:57:14 +03:00
Simonas Kazlauskas
2c9c70f17b
Deny extra_requirement_in_impl forward-compat lint
...
Part of #37166
2017-01-20 01:05:54 +02:00
Andrew Cann
bcdbe942e1
Make is_useful handle empty types properly
2017-01-03 15:31:46 +08:00
Jeffrey Seyfried
cfabce2230
Demote most backwards incompatible ambiguity errors from RFC 1560 to warnings.
2016-12-15 06:02:49 +00:00
Oliver Schneider
5beeb1eec7
remove useless lifetime outlives bounds
2016-12-07 13:14:47 +01:00
Eduard Burtescu
9aaf26e7aa
rustc: rework stability to be on-demand for type-directed lookup.
2016-11-28 04:18:11 +02:00
bors
3bf2be9cee
Auto merge of #37843 - nikomatsakis:issue-33685-hard-error, r=eddyb
...
make HR_LIFETIME_IN_ASSOC_TYPE deny-by-default
It's time to fix issue #32330 .
cc #33685
cc @arielb1
2016-11-22 06:39:42 -06:00
Jeffrey Seyfried
fa8c53bae4
Start warning cycle.
2016-11-22 01:52:04 +00:00
Niko Matsakis
a257d8d49f
make HR_LIFETIME_IN_ASSOC_TYPE deny-by-default
...
It's time to fix issue #32330 .
cc #33685
2016-11-17 16:50:59 -05:00
Niko Matsakis
ddabd509a8
compare-method lint
2016-11-01 14:08:56 -04:00
bors
75a87c54d0
Auto merge of #37378 - petrochenkov:nopat, r=eddyb
...
Prohibit patterns in trait methods without bodies
They are not properly type checked
```rust
trait Tr {
fn f(&a: u8); // <- This compiles
}
```
, mostly rejected by the parser already and generally don't make much sense.
This PR is kind of a missing part of https://github.com/rust-lang/rust/pull/35015 .
Given the [statistics from crater](https://github.com/rust-lang/rust/pull/37378#issuecomment-256154994 ), the effect of this PR is mostly equivalent to improving `unused_mut` lint.
cc https://github.com/rust-lang/rust/issues/35078#issuecomment-255707355 https://github.com/rust-lang/rust/pull/35015 https://github.com/rust-lang/rfcs/pull/1685 https://github.com/rust-lang/rust/issues/35203
r? @eddyb
2016-10-29 05:41:05 -07:00
Vadim Petrochenkov
2a85211040
Make sufficiently old or low-impact compatibility lints deny-by-default
2016-10-27 12:06:03 +03:00
Vadim Petrochenkov
811a2b91de
Prohibit patterns in trait methods without bodies
2016-10-26 20:55:16 +03:00