Skip to content

Commit

Permalink
Support Annotated[cls] in code-completion
Browse files Browse the repository at this point in the history
  • Loading branch information
fabioz committed Oct 19, 2024
1 parent 0e8bd0c commit 4f870bb
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -1059,7 +1059,8 @@ public boolean isNodeTypingUnionSubscript(IModule module, Object node) {
Subscript subscript = (Subscript) node;
String rep = NodeUtils.getFullRepresentationString(subscript.value);
if (rep != null && !rep.isBlank()) {
if (rep.equals("Union") || rep.endsWith(".Union")) {
if (rep.equals("Union") || rep.endsWith(".Union") || rep.equals("Annotated")
|| rep.endsWith(".Annotated")) {
return true;
}
}
Expand Down

0 comments on commit 4f870bb

Please sign in to comment.