Skip to content

Commit

Permalink
misc: fix deprecations
Browse files Browse the repository at this point in the history
  • Loading branch information
ice1000 committed May 27, 2024
1 parent 2ef5e51 commit 7e2a3e9
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ public class AyaRunLineMarkerContributor extends RunLineMarkerContributor {
final var actions = ExecutorAction.getActions(Integer.MAX_VALUE);
return new Info(AyaIcons.GUTTER_RUN, actions,
element -> ImmutableSeq.of(actions)
.mapNotNull(action -> getText(action, element))
.mapNotNull(action -> getText(action, createActionEvent(element)))
.joinToString("\n"));
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ private static boolean matches(@NotNull ProofShape ps, @NotNull Term term) {

static @NotNull String compile(int nested, @NotNull ProofShape ps) {
return switch (ps) {
case ProofShape.App app when app.terms.sizeEquals(1) -> compile(nested, app.terms.first().shape);
case ProofShape.App app when app.terms.sizeEquals(1) -> compile(nested, app.terms.getFirst().shape);
case ProofShape.App app -> paren(nested, app.terms.map(arg ->
braced(arg.explicit(), compile(nested + 1, arg.shape))));
case ProofShape.AnyId $ -> "((?![ (){}:]).)+";
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/org/aya/intellij/psi/AyaPsiReference.java
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ public AyaPsiReference(@NotNull AyaPsiElement element, TextRange rangeInElement)
@Override public @Nullable AyaPsiNamedElement resolve() {
return AyaLsp.use(myElement.getProject(),
() -> null,
lsp -> lsp.gotoDefinition(myElement).firstOrNull());
lsp -> lsp.gotoDefinition(myElement).getFirstOrNull());
}

@Override public PsiElement handleElementRename(@NotNull String newName) throws IncorrectOperationException {
Expand Down

0 comments on commit 7e2a3e9

Please sign in to comment.