MethodReturnTypeFix: updated fix to change method return type based on return statements in method body (IDEA-216275)

GitOrigin-RevId: e97990950039123c8c41921a71342b8ed60afdee
This commit is contained in:
Artemiy Sartakov
2019-07-04 12:09:26 +07:00
committed by intellij-monorepo-bot
parent 52aa1ae553
commit 42d733a694
42 changed files with 381 additions and 55 deletions

View File

@@ -1,5 +1,5 @@
class Bug {
static A test(A[] as) {
static A <error descr="Invalid return type">test</error>(A[] as) {
for (<error descr="Incompatible types. Found: 'Bug.B', required: 'Bug.A'">B b</error> : as) {
<error descr="Incompatible types. Found: 'Bug.B', required: 'Bug.A'">return b;</error>
}