Lines 324-331
Link Here
|
324 |
if(this.genericsPtr > -1) { |
324 |
if(this.genericsPtr > -1) { |
325 |
ASTNode node = this.genericsStack[this.genericsPtr]; |
325 |
ASTNode node = this.genericsStack[this.genericsPtr]; |
326 |
if(node instanceof Wildcard && ((Wildcard)node).bound == this.assistNode){ |
326 |
if(node instanceof Wildcard && ((Wildcard)node).bound == this.assistNode){ |
327 |
buildMoreGenericsCompletionContext(node); |
327 |
int kind = topKnownElementKind(COMPLETION_OR_ASSIST_PARSER); |
328 |
return; |
328 |
if (kind == K_BINARY_OPERATOR) { |
|
|
329 |
int info = topKnownElementInfo(COMPLETION_OR_ASSIST_PARSER); |
330 |
if (info == LESS) { |
331 |
buildMoreGenericsCompletionContext(node, true); |
332 |
return; |
333 |
} |
334 |
} |
335 |
if(this.identifierLengthPtr > -1 && this.identifierLengthStack[this.identifierLengthPtr]!= 0) { |
336 |
this.pushOnElementStack(K_BINARY_OPERATOR, LESS); |
337 |
buildMoreGenericsCompletionContext(node, false); |
338 |
return; |
339 |
} |
329 |
} |
340 |
} |
330 |
} |
341 |
} |
331 |
|
342 |
|
Lines 406-412
Link Here
|
406 |
} |
417 |
} |
407 |
} |
418 |
} |
408 |
if(node == this.assistNode){ |
419 |
if(node == this.assistNode){ |
409 |
buildMoreGenericsCompletionContext(node); |
420 |
buildMoreGenericsCompletionContext(node, true); |
410 |
} |
421 |
} |
411 |
} |
422 |
} |
412 |
} |
423 |
} |
Lines 854-860
Link Here
|
854 |
} |
865 |
} |
855 |
} |
866 |
} |
856 |
} |
867 |
} |
857 |
private void buildMoreGenericsCompletionContext(ASTNode node) { |
868 |
private void buildMoreGenericsCompletionContext(ASTNode node, boolean consumeTypeArguments) { |
858 |
int kind = topKnownElementKind(COMPLETION_OR_ASSIST_PARSER); |
869 |
int kind = topKnownElementKind(COMPLETION_OR_ASSIST_PARSER); |
859 |
if(kind != 0) { |
870 |
if(kind != 0) { |
860 |
int info = topKnownElementInfo(COMPLETION_OR_ASSIST_PARSER); |
871 |
int info = topKnownElementInfo(COMPLETION_OR_ASSIST_PARSER); |
Lines 875-881
Link Here
|
875 |
} |
886 |
} |
876 |
if(info == LESS && node instanceof TypeReference) { |
887 |
if(info == LESS && node instanceof TypeReference) { |
877 |
if(this.identifierLengthPtr > -1 && this.identifierLengthStack[this.identifierLengthPtr]!= 0) { |
888 |
if(this.identifierLengthPtr > -1 && this.identifierLengthStack[this.identifierLengthPtr]!= 0) { |
878 |
this.consumeTypeArguments(); |
889 |
if (consumeTypeArguments) this.consumeTypeArguments(); |
879 |
TypeReference ref = this.getTypeReference(0); |
890 |
TypeReference ref = this.getTypeReference(0); |
880 |
if(prevKind == K_PARAMETERIZED_CAST) { |
891 |
if(prevKind == K_PARAMETERIZED_CAST) { |
881 |
ref = computeQualifiedGenericsFromRightSide(ref, 0); |
892 |
ref = computeQualifiedGenericsFromRightSide(ref, 0); |