Skip to content

Commit

Permalink
Fix build on JDK 23 (#1129)
Browse files Browse the repository at this point in the history
  • Loading branch information
gnodet authored Dec 10, 2024
1 parent c6378cd commit 2743957
Show file tree
Hide file tree
Showing 8 changed files with 20 additions and 15 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/master-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ jobs:
strategy:
matrix:
os: [ ubuntu-latest, ubuntu-20.04, windows-latest, macos-latest ]
java: [ '22' ]
java: [ '23' ]
steps:
- uses: actions/checkout@v4

Expand Down
5 changes: 3 additions & 2 deletions builtins/src/main/java/org/jline/builtins/ScreenTerminal.java
Original file line number Diff line number Diff line change
Expand Up @@ -25,15 +25,16 @@
* limitations under the License.
*/

/**
/*
* Based on http://antony.lesuisse.org/software/ajaxterm/
* Public Domain License
*/

/**
/*
* See http://www.ecma-international.org/publications/standards/Ecma-048.htm
* and http://vt100.net/docs/vt510-rm/
*/

import java.lang.reflect.Array;
import java.util.ArrayList;
import java.util.Arrays;
Expand Down
1 change: 1 addition & 0 deletions demo/src/main/java/org/apache/felix/gogo/jline/Posix.java
Original file line number Diff line number Diff line change
Expand Up @@ -1865,6 +1865,7 @@ public static class SortComparator implements Comparator<String> {
private char separator;
private List<Key> sortKeys;

@SuppressWarnings("this-escape")
public SortComparator(
boolean caseInsensitive,
boolean reverse,
Expand Down
3 changes: 3 additions & 0 deletions groovy/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,9 @@
<plugin>
<groupId>org.codehaus.gmavenplus</groupId>
<artifactId>gmavenplus-plugin</artifactId>
<configuration>
<targetBytecode>${java.release.version}</targetBytecode>
</configuration>
<executions>
<execution>
<goals>
Expand Down
4 changes: 2 additions & 2 deletions jansi-core/src/main/java/org/jline/jansi/Ansi.java
Original file line number Diff line number Diff line change
Expand Up @@ -900,9 +900,9 @@ public String toString() {
return builder.toString();
}

///////////////////////////////////////////////////////////////////
// =================================================================
// Private Helper Methods
///////////////////////////////////////////////////////////////////
// =================================================================

private Ansi appendEscapeSequence(char command) {
flushAttributes();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ public boolean isActive() {
return !dead;
} // isClosed

/****** Event handling ****************/
// ============= Event handling =============

/**
* Method that registers a ConnectionListener with the
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ public class TelnetIO {
*/
protected static final int AO = 245;

/**** Implementation of OutputStream ****************************************************/
// ============= Implementation of OutputStream ===============
/**
* Are You There
*/
Expand Down Expand Up @@ -187,9 +187,9 @@ public class TelnetIO {
*/
protected static final int SEND = 1;

/**** End implementation of OutputStream ***********************************************/
// ============ End implementation of OutputStream ============

/**** Implementation of InputStream ****************************************************/
// ============== Implementation of InputStream ===============
/**
* Telnet Option: Logout<br>
* This allows nice goodbye to time-outed or unwanted clients.
Expand All @@ -206,7 +206,7 @@ public class TelnetIO {
protected static final int LM_EDIT = 1;
protected static final int LM_TRAPSIG = 2;

/**** Implementation of InputStream ****************************************************/
// ============== Implementation of InputStream ===============

/****
* Following methods implement init/request/answer procedures for telnet
Expand All @@ -219,12 +219,13 @@ public class TelnetIO {
protected static final int LM_SLC_NOSUPPORT = 0;
protected static final int LM_SLC_DEFAULT = 3;

/**** End telnet protocol level communication methods *******************************/
// ==== End telnet protocol level communication methods ===

protected static final int LM_SLC_VALUE = 2;

/** Constants declaration ***********************************************/
// ============= Constants declaration ====================

// Telnet Protocoll Constants
// Telnet Protocol Constants
protected static final int LM_SLC_CANTCHANGE = 1;

protected static final int LM_SLC_LEVELBITS = 3;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,7 @@
import java.nio.charset.MalformedInputException;
import java.nio.charset.UnmappableCharacterException;

/**
*
/*
* NOTE for JLine: the default InputStreamReader that comes from the JRE
* usually read more bytes than needed from the input stream, which
* is not usable in a character per character model used in the terminal.
Expand Down

0 comments on commit 2743957

Please sign in to comment.