Commit graph

2483 commits

Author SHA1 Message Date
flip1995
3fe5eea4e4
Fix get_def_path
This fix is obsolet once rust-lang/rust#59779 and #3926 is merged.
2019-04-12 11:59:06 +02:00
bors
2278814c8e Auto merge of #3931 - phansch:3891, r=flip1995
Fix ICE in decimal_literal_representation lint

Handling the integer parsing properly instead of just unwrapping.

Note that the test is not catching the ICE because plain UI tests
[currently hide ICEs][compiletest_issue]. Once that issue is fixed, this
test would fail properly again.

Fixes #3891

[compiletest_issue]: https://github.com/laumann/compiletest-rs/issues/169
2019-04-10 20:57:15 +00:00
Philipp Hansch
ab6b949224
Refactor check_lit method 2019-04-10 21:05:56 +02:00
Tomas Koutsky
603996c9d5 Support updated type dependent def ID getter 2019-04-10 16:18:02 +02:00
Philipp Hansch
1fd2451b90
Code formatting/cleanup 2019-04-10 07:50:34 +02:00
Philipp Hansch
2b0dc39f5b
Don't emit useless_attribute lint in external macros 2019-04-10 07:30:59 +02:00
bors
37f5c1ec73 Auto merge of #3925 - phansch:3741, r=flip1995
Fix ICE in suspicious_else_formatting

Fixes #3741
2019-04-09 07:13:08 +00:00
Philipp Hansch
0307ff020c
Fix ICE in decimal_literal_representation lint
Handling the integer parsing properly instead of just unwrapping.

Note that the test is not catching the ICE because plain UI tests
[currently hide ICEs][compiletest_issue]. Once that issue is fixed, this
test would fail properly again.

[compiletest_issue]: https://github.com/laumann/compiletest-rs/issues/169
2019-04-08 22:16:34 +02:00
Klemen Košir
560fd163d6
Escape a single quote in single_char_pattern hint 2019-04-08 21:55:50 +09:00
bors
4fdd113bed Auto merge of #3921 - euclio:single-char-names-multispan, r=flip1995
use a multispan for MANY_SINGLE_CHAR_NAMES
2019-04-08 08:42:13 +00:00
bors
e91ba8af85 Auto merge of #3848 - felix91gr:null_transmute, r=flip1995
Transmuting known null ptr to ref

Working on implementing #628
2019-04-08 07:20:25 +00:00
bors
42e1cf3763 Auto merge of #3901 - rail-rain:issue_1670, r=flip1995
Fix `explicit_counter_loop` suggestion

#1670

This code seems to me to work, but I have two question.
* Because range expression desugared in hir, `Sugg::hir` doesn't add parenthesis to range expression.  Which function is better to check range do you think, `check_for_loop_explicit_counter` or `hir_from_snippet`?
* Do you think we need to distinguish between range expression and struct expression that creates `std::ops::Range*`?
2019-04-08 06:28:15 +00:00
Philipp Hansch
547c5c0667
cargo fmt 2019-04-08 07:56:54 +02:00
Philipp Hansch
60c1bb0546
Fix ICE in suspicious_else_formatting 2019-04-07 11:11:06 +02:00
Andy Russell
0d50d44ea6
use a multispan for MANY_SINGLE_CHAR_NAMES 2019-04-05 10:07:39 -04:00
Matthias Krüger
920e47ceb5 NFC: fix typos 2019-04-04 11:15:30 +02:00
Matthias Krüger
c81e43b92c rustup https://github.com/rust-lang/rust/pull/59657
commit: 4122d2221e
2019-04-03 10:48:54 +02:00
Félix Fischer
069957a8ad Add TransmutingNull Lint
* Late Lint pass, catches:
  * One liner: 0 -> null -> transmute
  * One liner: std:null() -> transmute
  * Const (which resolves to null) -> transmute
* UI Test case for Lint
* Updated test for issue 3849, because now the lint that code generated is in Clippy.
* Expanded `const.rs` miri-based Constant Folding code, to cover
  raw pointers
2019-04-02 11:39:43 -03:00
Philipp Hansch
b253c564d5
Rustup to https://github.com/rust-lang/rust/pull/58805 2019-04-01 20:37:05 +02:00
Félix Fischer
491f72442e
Updated source to match with recent rustc master toolchain changes 2019-04-01 20:37:05 +02:00
flip1995
bbb7963735
Fix dogfood error of question_mark lint fix 2019-04-01 20:37:05 +02:00
flip1995
6f01ecfefd
Fix question_mark lint+test 2019-04-01 20:37:05 +02:00
rail
2b82c71b55 use span_lint_and_sugg in explicit_counter_loop 2019-03-28 08:51:57 +09:00
Félix Fischer
3cff06a0eb Fix some test failures 2019-03-26 13:57:03 -03:00
Oliver Scherer
d020565ed2 Hacky rustup 2019-03-26 10:55:03 +01:00
Matthias Krüger
b5d82524b4 run cargo fmt 2019-03-23 23:39:58 +01:00
Matthias Krüger
e17dd4efa9 rustup https://github.com/rust-lang/rust/pull/59096/ 2019-03-23 23:37:38 +01:00
rail
9698e41994 Change explicit_counter_loop's message to add parentheses if necessary 2019-03-23 15:36:48 +09:00
rail
bd6c2df066 Change explicit_counter_loop's message to reflect original variable name 2019-03-23 15:30:17 +09:00
Mateusz Mikuła
6cb0605600 Cargo fmt 2019-03-18 13:39:11 +01:00
Mateusz Mikuła
664391c5f8 Drop range_contains feature 2019-03-18 12:54:10 +01:00
Mateusz Mikuła
8feb2c6b2f Fix rustfmt::skip detection 2019-03-18 12:54:10 +01:00
Mateusz Mikuła
fb7699d9e5 Rework clippy detection in attribute lint 2019-03-18 12:54:10 +01:00
Mateusz Mikuła
0ea5e38a9e name -> check_name 2019-03-18 12:54:10 +01:00
Mateusz Mikuła
4bb6c87b08 span -> span() 2019-03-18 12:54:10 +01:00
Mateusz Mikuła
b25564fc8a name -> ident_str 2019-03-18 12:54:10 +01:00
Mateusz Mikuła
e63a685412 NestedMetaItemKind -> NestedMetaItem 2019-03-18 12:54:10 +01:00
Mateusz Mikuła
cf71caa71d Drop redundant & 2019-03-18 12:54:10 +01:00
Mateusz Mikuła
cb3aa7480c Fix path_qualified
As suggested by eddyb
2019-03-18 12:54:10 +01:00
Mateusz Mikuła
9b7ff501a6 Replace most of ty:Ty with Ty 2019-03-18 12:54:10 +01:00
flip1995
4832a853c7
Feed dog 2019-03-16 15:39:02 +01:00
flip1995
180e07e99e
Adapt paths to new formatting 2019-03-16 15:22:31 +01:00
flip1995
3c4616d303
cargo fmt 2019-03-16 11:51:57 +01:00
flip1995
254fad95de
Use LocalInternedString inside of AbsolutePathPrinter 2019-03-16 11:45:29 +01:00
flip1995
dae5c9c685
AbsolutePathBuffer -> AbsolutePathPrinter 2019-03-16 11:17:36 +01:00
flip1995
2d8618e95c
Remove ty::TyKind from eta_reduction and replace it with ty::Ty 2019-03-16 11:10:33 +01:00
flip1995
8eadbfd35b
parent_def_id -> parent 2019-03-15 23:44:04 +01:00
flip1995
dcbd3aefa2
item_path_str -> def_path_str 2019-03-15 23:43:42 +01:00
flip1995
31435cd7f5
Reimplement AbsolutePathBuffer 2019-03-15 23:42:46 +01:00
bors
e7806413c6 Auto merge of #3883 - daxpedda:missing_docs_in_private_items, r=phansch
Add `doc(include = ...)` detection to `missing_docs_in_private_items`

The whole `missing documentation in crate` part doesn't have any tests. If I should add test cases tell me.
2019-03-15 06:18:28 +00:00