mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-01-03 15:50:52 +07:00
split declaration: detect same variables after declaration (IDEA-175261)
This commit is contained in:
@@ -0,0 +1,15 @@
|
||||
// "Split into declaration and assignment" "true"
|
||||
class Test {
|
||||
{
|
||||
int i;
|
||||
for (i = 0; i<10; i++) {
|
||||
System.out.println();
|
||||
}
|
||||
|
||||
new Runnable() {
|
||||
{
|
||||
int i = 0;
|
||||
}
|
||||
};
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
// "Split into declaration and assignment" "true"
|
||||
class Test {
|
||||
{
|
||||
for (int i<caret>=0; i<10; i++) {
|
||||
System.out.println();
|
||||
}
|
||||
|
||||
new Runnable() {
|
||||
{
|
||||
int i = 0;
|
||||
}
|
||||
};
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
// "Split into declaration and assignment" "false"
|
||||
class Test {
|
||||
{
|
||||
for (int i<caret>=0; i<10; i++) {
|
||||
System.out.println();
|
||||
}
|
||||
Runnable r = () -> {int i = 0;};
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user