mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-04-17 20:11:25 +07:00
Java: add cast to single branch of conditional expression when possible (IDEA-358278)
GitOrigin-RevId: 8f3137172d8a1526da2228e3c9ed911f9805c16c
This commit is contained in:
committed by
intellij-monorepo-bot
parent
83bba063e7
commit
18cb209fa7
@@ -0,0 +1,7 @@
|
||||
// "Cast expression to 'byte'" "true-preview"
|
||||
class A {
|
||||
void f(boolean v) {
|
||||
int i = 10;
|
||||
Byte b = v ? 100 : (byte) i;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
// "Cast expression to 'byte'" "true-preview"
|
||||
class A {
|
||||
void f(boolean v) {
|
||||
int i = 10;
|
||||
Byte b = <caret> v ? 100 : i;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user