summaryrefslogtreecommitdiff
path: root/java/java-psi-impl/src/com/intellij/psi/impl/source/resolve/graphInference/InferenceVariable.java
diff options
context:
space:
mode:
authorTor Norbye <tnorbye@google.com>2014-08-20 17:01:23 -0700
committerTor Norbye <tnorbye@google.com>2014-08-20 17:01:23 -0700
commit1aa2e09bdbd413eacb677e9fa4b50630530d0656 (patch)
tree2f4cc6d69645bd460aa253fdecb606d764fbd25d /java/java-psi-impl/src/com/intellij/psi/impl/source/resolve/graphInference/InferenceVariable.java
parent02cf98d65c798d368fcec43ed64a001d513bdd4f (diff)
downloadidea-1aa2e09bdbd413eacb677e9fa4b50630530d0656.tar.gz
Snapshot idea/138.1696 from git://git.jetbrains.org/idea/community.git
Change-Id: I50c97b83a815ce635e49a38380ba5b8765e4b16a
Diffstat (limited to 'java/java-psi-impl/src/com/intellij/psi/impl/source/resolve/graphInference/InferenceVariable.java')
-rw-r--r--java/java-psi-impl/src/com/intellij/psi/impl/source/resolve/graphInference/InferenceVariable.java10
1 files changed, 10 insertions, 0 deletions
diff --git a/java/java-psi-impl/src/com/intellij/psi/impl/source/resolve/graphInference/InferenceVariable.java b/java/java-psi-impl/src/com/intellij/psi/impl/source/resolve/graphInference/InferenceVariable.java
index a19961f4c3a9..6bc9e0b89871 100644
--- a/java/java-psi-impl/src/com/intellij/psi/impl/source/resolve/graphInference/InferenceVariable.java
+++ b/java/java-psi-impl/src/com/intellij/psi/impl/source/resolve/graphInference/InferenceVariable.java
@@ -115,6 +115,16 @@ public class InferenceVariable extends LightTypeParameter {
return dependencies;
}
+ public boolean hasInstantiation(InferenceSession session) {
+ List<PsiType> bounds = getBounds(InferenceBound.EQ);
+ if (bounds != null) {
+ for (PsiType bound : bounds) {
+ if (session.isProperType(bound)) return true;
+ }
+ }
+ return false;
+ }
+
public boolean isThrownBound() {
return myThrownBound;
}