mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-01-04 00:20:55 +07:00
Java:Highlight "Recursive constructor invocation" error on the constructor call (IDEA-356563)
GitOrigin-RevId: ec04cb0aa5b234ea9814d78400c83fa70e6bd29b
This commit is contained in:
committed by
intellij-monorepo-bot
parent
84e8c4509a
commit
291bb89726
@@ -2,12 +2,12 @@
|
||||
|
||||
|
||||
class s {
|
||||
<error descr="Recursive constructor invocation">s()</error> {
|
||||
this();
|
||||
s() {
|
||||
<error descr="Recursive constructor call">this()</error>;
|
||||
}
|
||||
|
||||
<error descr="Recursive constructor invocation">s(int i)</error> {
|
||||
this(2);
|
||||
s(int i) {
|
||||
<error descr="Recursive constructor call">this(2)</error>;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -16,11 +16,11 @@ class c {
|
||||
this(2);
|
||||
}
|
||||
|
||||
<error descr="Recursive constructor invocation">c(int i)</error> {
|
||||
this(1,1);
|
||||
c(int i) {
|
||||
<error descr="Recursive constructor call">this(1,1)</error>;
|
||||
}
|
||||
<error descr="Recursive constructor invocation">c(int i, int k)</error> {
|
||||
this(1);
|
||||
c(int i, int k) {
|
||||
<error descr="Recursive constructor call">this(1)</error>;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -34,4 +34,12 @@ class cv {
|
||||
}
|
||||
|
||||
cv(int i,int j) {}
|
||||
}
|
||||
class X {
|
||||
private final int value;
|
||||
|
||||
X() {
|
||||
<error descr="Recursive constructor call">this()</error>;
|
||||
<error descr="Variable 'value' might already have been assigned to">value</error> = 1;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user