Co-Authored-By: Claude Sonnet 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01B38FGKKam5SCGgwgduVAh3
18 lines
1.2 KiB
Bash
Executable File
18 lines
1.2 KiB
Bash
Executable File
#!/usr/bin/env bash
|
|
# Public-API diffs between JDK 25 (LTS), 26 and 27, produced from javap dumps of every exported class.
|
|
# ./scripts/api-diff.sh -> docs/output/50-vector-api-surface.txt, 51-api-diff-26-to-27.txt, 52-api-diff-25-to-26.txt
|
|
# The dumps are 5 MB each and take a few minutes to build, so they are cached in build/apidiff/.
|
|
set -euo pipefail
|
|
source "$(dirname "$0")/env.sh"
|
|
D="$ROOT/build/apidiff"; mkdir -p "$D"
|
|
for v in 25 26 27; do
|
|
jdk="JDK$v"
|
|
[ -s "$D/api-$v.txt" ] || python3 "$ROOT/api-diff/dump_api.py" "${!jdk}" "$D/api-$v.txt"
|
|
done
|
|
{ echo "# Public API removed/added/changed between JDK 26 and 27 (javap -public of every exported class; internal packages skipped)"; echo
|
|
python3 "$ROOT/api-diff/apidiff.py" "$D/api-26.txt" "$D/api-27.txt"; } > "$OUT/51-api-diff-26-to-27.txt"
|
|
{ echo "# Public API removed/added/changed between JDK 25 and 26"; echo
|
|
python3 "$ROOT/api-diff/apidiff.py" "$D/api-25.txt" "$D/api-26.txt"; } > "$OUT/52-api-diff-25-to-26.txt"
|
|
{ echo "# jdk.incubator.vector: what changed between 26 and 27 (JEP 529 was the 11th incubation in 26, JEP 537 is the 12th in 27)"; echo
|
|
python3 "$ROOT/api-diff/apidiff.py" "$D/api-26.txt" "$D/api-27.txt" --vector-only; } > "$OUT/50-vector-api-surface.txt"
|