Pavel Dolgov
8ce43b883c
Java: Intention that wraps list/set/map with Collections.unmodifiable - handle ternary 'if' (IDEA-93154)
2019-02-21 18:03:24 +03:00
Pavel Dolgov
96b9ab4f80
Java: Intention that wraps list/set/map with Collections.unmodifiable - handle the caret at the end of the expression (IDEA-93154)
2019-02-21 18:03:24 +03:00
Pavel Dolgov
0267b104b3
Java: Intention that wraps list/set/map with Collections.unmodifiable - check the required type (IDEA-93154)
2019-02-21 18:03:24 +03:00
Tagir Valeev
1f132fb51e
ConstantConditionalExpressionInspection: respect precedence when creating type-cast
...
Fixes EA-137355 - CCE: ConstantConditionalExpressionInspection$ConstantConditionalFix.doFix
Also fix removing parentheses inside RemoveRedundantCastUtil#removeCast
2019-02-21 13:14:16 +07:00
Pavel Dolgov
63092d9c2e
Java: Intention that wraps list/set/map with Collections.unmodifiableList/Set/Map (IDEA-93154)
2019-02-20 18:00:15 +03:00
Pavel Dolgov
ec58711cf3
Java: Quick fix for missing 'return' in lambda body (IDEA-169551)
2019-02-20 13:27:57 +03:00
Tagir Valeev
5c0748b0bc
StreamApiMigrationInspection: BufferedReaderLines: support parentheses around readLine in while scenario
2019-02-18 12:37:12 +07:00
Tagir Valeev
7a897157f1
MergeFilterChainAction: support parentheses
2019-02-08 15:24:53 +07:00
Anna.Kozlova
a98a18ce8a
calc expected type on the left of assignment based on standalone expression type from the right side (IDEA-199273)
2019-02-07 15:59:00 +01:00
Artemiy Sartakov
043c2d563e
Field can be local: added support for nested and local classes (IDEA-206647)
2019-02-07 17:27:00 +07:00
Tagir Valeev
5de8f58f34
Replace with trivial lambda default fixed after 2cfd1ece23
2019-02-07 10:58:44 +07:00
Pavel Dolgov
d9412eba69
Java: Fixed typos in test data file names (IDEA-203895)
2019-02-06 18:40:08 +03:00
Bas Leijdekkers
4e7a841173
qualify field access in initializer when shadowed by new declaration (IDEA-173780)
2019-02-06 16:09:30 +01:00
Anna.Kozlova
dac182b6d9
var -> explicit type: fix for foreach parameter (IDEA-206640)
2019-02-05 16:36:29 +01:00
Artemiy Sartakov
1b87c1a508
ConvertToLocalInspection: changed quick-fix to explicitly show type of code block where field is used (IDEA-CR-42222)
2019-02-05 13:26:10 +07:00
Anna.Kozlova
1ace9ab2c3
lambda -> method ref: reuse comment tracker (IDEA-189934)
2019-02-04 15:21:43 +01:00
Pavel Dolgov
cf34272833
Java: More tests for intention to split switch branch with multiple values into separate branches (IDEA-203895)
2019-02-04 12:33:41 +03:00
Tagir Valeev
15e0df11f9
IDEA-206497 Replace with stream: support intermediate map operations in counting loops
2019-02-04 14:20:39 +07:00
Pavel Dolgov
4c260c88bc
Java: Improvements in intention to split switch branch with multiple values into separate branches (IDEA-203895)
2019-02-01 13:11:28 +03:00
Artemiy Sartakov
4b5b6574aa
IntegerMultiplicationImplicitCastToLong: added quick-fix (IDEA-206024)
2019-02-01 15:12:50 +07:00
Anna.Kozlova
f2b9476d0f
disable create method from usage/change signature based on void argument (IDEA-205710)
2019-01-31 18:22:13 +01:00
Tagir Valeev
8da8dca8e0
IDEA-200455 Suggest to replace (a, b) -> a + b lambdas with Integer::sum, Long::sum, Double::sum
2019-01-31 14:21:13 +07:00
Pavel Dolgov
1bb82a7f5c
Java: Intention to split switch branch with multiple values into separate branches (IDEA-203895)
2019-01-30 15:52:26 +03:00
Anna.Kozlova
c7af135fba
"fix all" should retrieve file to run from the problem description when present (IDEA-206216)
...
otherwise injected file could be preferred instead of top level one
2019-01-28 20:24:45 +01:00
Artemiy Sartakov
6fbd5cc914
ConvertToLocalInspection: CR fixes (IDEA-CR-42222)
...
1. localVariableIsCopy -> isLocalVariableCopy
2. added more precise convert to local quick fix message (with info about to where field will be inlined)
3. fixed tests for new convert to local quick fix messages
4. removed inlineVariable(PsiVariable, PsiExpression)
2019-01-28 18:32:01 +07:00
Anna.Kozlova
489bed949a
disable add catch exception for method references (IDEA-205952)
2019-01-24 13:59:37 +01:00
Tagir Valeev
bcc8d9d5ba
CreateLocalFromUsageFix, ExpectedTypesProvider fixes (incl. EA-134473 - assert: CreateLocalFromUsageFix.getAnchor)
2019-01-24 18:49:29 +07:00
Tagir Valeev
c016d59b0c
EmptyStatementBodyInspection: delete body on empty foreach
2019-01-21 16:40:02 +07:00
Dmitry Batkovich
183921ba14
add test for IDEA-205525
2019-01-18 22:19:56 +03:00
Artemiy Sartakov
52f49b5c5f
ConvertToLocalInspection: inline created local variable if this variable is a copy of initializer (IDEA-33733)
2019-01-17 20:26:42 +07:00
Tagir Valeev
c51dbd9bc6
IDEA-205482 "Use removal by object" fix may change semantics for List<Integer>
2019-01-16 16:04:35 +07:00
Tagir Valeev
cfd0c17038
IDEA-205308 'Replace with max()' produces uncompilable source
2019-01-15 13:14:19 +07:00
Tagir Valeev
a3ed07435e
IDEA-205309 'Replace with findFirst()' produces uncompilable source
2019-01-15 12:32:12 +07:00
Tagir Valeev
c68df6edc2
ConvertSwitchToIfIntention: preserve comments from expression when only default branch is present
2019-01-10 17:24:20 +07:00
Tagir Valeev
0835bd0976
ConvertSwitchToIfIntention: fix processing of empty blocks
...
IDEA-205137 `Replace Switch with If` produce exceptions
IDEA-205122 Unwrap switch fails with exception
2019-01-10 12:40:04 +07:00
Anna.Kozlova
e0e26f5b95
fix remove redundant suppress from javadoc tag (IDEA-205073)
2019-01-08 16:16:05 +01:00
Anna.Kozlova
55820ccd15
predict functional type in assignment context (IDEA-199264)
2019-01-07 19:09:17 +01:00
Tagir Valeev
725cf20422
IDEA-204917 "Loop can be collapsed with Stream API" creates uncompilable results in some cases
...
1. Look for references inside IntStream.iterate condition (Java9+)
2. When simplifying IntStream.range(...).map(i -> arr[i]) check if arr expression don't refer to i
2019-01-06 10:25:15 +07:00
Anna.Kozlova
f105cd4e0c
extract if: preserve comments inside redundant parenthesis
2019-01-04 11:00:05 +01:00
Anna Kozlova
4d6dd142f0
fix testdata
2018-12-28 21:30:43 +01:00
Anna.Kozlova
b09a6328d4
change signature from usage: disable when permute arguments fix is available (IDEA-176975)
2018-12-28 19:08:45 +01:00
Dmitry Jemerov
f2f79946b1
Don't use title case in quickfix names (Assign parameter to field)
2018-12-28 16:42:12 +01:00
Tagir Valeev
7addf9e702
IDEA-204717 Can't convert enhanced 'switch' to 'if' if a branch's body contains an end-of-line comment
2018-12-26 21:05:24 +07:00
Roman.Ivanov
ffea561fc3
ComparatorCombinatorsInspection: fix case, where inspection failed to recognize chain
2018-12-26 17:33:53 +07:00
Tagir Valeev
9fa4497ced
IDEA-204701 Redundant collection operation: suggest emptyIterator()
2018-12-25 16:17:24 +07:00
Tagir Valeev
03e4f37774
ExpectedTypesProvider and CreateLocalFromUsageFix updated for Java 12 (IDEA-204006)
2018-12-21 16:32:43 +07:00
Tagir Valeev
92048254c1
VariableNameGenerator: fixed failing tests
2018-12-21 13:31:29 +07:00
Tagir Valeev
04f7352faa
RemoveUnusedVariableUtil: code generation fixes
...
1. Support Java 12 switch rules and switch expressions (IDEA-203692)
2. Support void expression lambdas
3. Fix PSI structure when expression list statement is reduced to single expression
2018-12-20 13:50:01 +07:00
Tagir Valeev
362b8d0b34
Stream API migration: do not convert continue statements which belong to the nested loops (IDEA-204250)
2018-12-18 12:28:52 +07:00
Tagir Valeev
5d4a0b8197
Basic support of switch expressions in StatementExtractor/SideEffectChecker
...
Fixes IDEA-204138 Exception in "statement with empty body" inspection with switch expression
Fixes EA-133610 - REWA: StatementExtractor.createNode
2018-12-13 17:42:28 +07:00