Skip to content

Commit

Permalink
Add JLeftPadded.Location.WILDCARD_BOUND
Browse files Browse the repository at this point in the history
This particular location definition was missing.
  • Loading branch information
knutwannheden committed Jun 5, 2024
1 parent ddde0ae commit 5b5d72c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1332,13 +1332,7 @@ public J visitWildcard(J.Wildcard wildcard, P p) {
} else {
w = (J.Wildcard) temp;
}
if (w.getPadding().getBound() != null) {
w = w.getPadding().withBound(
w.getPadding().getBound().withBefore(
visitSpace(w.getPadding().getBound().getBefore(), Space.Location.WILDCARD_BOUND, p)
)
);
}
w = w.getPadding().withBound(visitLeftPadded(w.getPadding().getBound(), JLeftPadded.Location.WILDCARD_BOUND, p));
w = w.withBoundedType(visitAndCast(w.getBoundedType(), p));
if (w.getBoundedType() != null) {
// i.e. not a "wildcard" type
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,8 @@ public enum Location {
TRY_FINALLY(Space.Location.TRY_FINALLY),
UNARY_OPERATOR(Space.Location.UNARY_OPERATOR),
VARIABLE_INITIALIZER(Space.Location.VARIABLE_INITIALIZER),
WHILE_CONDITION(Space.Location.WHILE_CONDITION);
WHILE_CONDITION(Space.Location.WHILE_CONDITION),
WILDCARD_BOUND(Space.Location.WILDCARD_BOUND);

private final Space.Location beforeLocation;

Expand Down

0 comments on commit 5b5d72c

Please sign in to comment.