Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ jobs:
printf '%s/jextract-25/bin\n' "$RUNNER_TOOL_CACHE" >> "$GITHUB_PATH"
env:
# NOTE: keep this in sync with deploy, docs
JEXTRACT_URL: https://download.java.net/java/early_access/jextract/25/1/openjdk-25-jextract+1-1
JEXTRACT_URL: https://download.java.net/java/early_access/jextract/25/2/openjdk-25-jextract+2-4
- name: Run tests
run: mvn --no-transfer-progress test
- name: Patch SpotBugs SARIF report
Expand Down
9 changes: 6 additions & 3 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,15 +43,18 @@ jobs:
cd tree-sitter-java
tree-sitter generate --abi=15
make all install PREFIX="$RUNNER_TOOL_CACHE/tree-sitter/lib"
- name: Set up jextract
- name: Generate code with jextract
run: |-
curl -LSs '${{env.JEXTRACT_URL}}_linux-x64_bin.tar.gz' | tar xzf - -C "$RUNNER_TOOL_CACHE"
printf '%s/jextract-25/bin\n' "$RUNNER_TOOL_CACHE" >> "$GITHUB_PATH"
mvn --no-transfer-progress antrun:run@jextract
sed -i '${{env.TS_SHARED}}' -e '/C_LONG =/s/"long"/"long long"/'
env:
# NOTE: keep this in sync with ci, docs
JEXTRACT_URL: https://download.java.net/java/early_access/jextract/25/1/openjdk-25-jextract+1-1
JEXTRACT_URL: https://download.java.net/java/early_access/jextract/25/2/openjdk-25-jextract+2-4
TS_SHARED: target/generated-sources/jextract/io/github/treesitter/jtreesitter/internal/TreeSitter$shared.java
- name: Deploy to Maven Central
run: mvn --no-transfer-progress deploy -Dspotbugs.skip=true
run: mvn --no-transfer-progress deploy -Dspotbugs.skip=true -Djextract.skip=true
env:
SONATYPE_USERNAME: ${{secrets.SONATYPE_USERNAME}}
SONATYPE_TOKEN: ${{secrets.SONATYPE_TOKEN}}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ jobs:
printf '%s/jextract-25/bin\n' "$RUNNER_TOOL_CACHE" >> "$GITHUB_PATH"
env:
# NOTE: keep this in sync with ci, deploy
JEXTRACT_URL: https://download.java.net/java/early_access/jextract/25/1/openjdk-25-jextract+1-1
JEXTRACT_URL: https://download.java.net/java/early_access/jextract/25/2/openjdk-25-jextract+2-4
- name: Build javadoc
run: mvn --no-transfer-progress javadoc:javadoc antrun:run@fix-javadoc
- name: Upload pages artifact
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,8 @@ public SymbolLookup get(Arena arena) {
lookup = lookup.or(libraryLookup.get(arena));
}

return lookup.or((name) -> findLibrary(arena).find(name)).or(Linker.nativeLinker().defaultLookup());
return lookup.or((name) -> findLibrary(arena).find(name))
.or(Linker.nativeLinker().defaultLookup());
}

private static SymbolLookup findLibrary(Arena arena) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
*
* <ul>
* <li>
* JDK 22 (for the
* JDK 23+ (for the
* <a href="https://docs.oracle.com/en/java/javase/22/core/foreign-function-and-memory-api.html">
* Foreign Function and Memory API
* </a>)
Expand Down
Loading