Skip to content
Draft
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
8 changes: 4 additions & 4 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ jobs:
- uses: actions/setup-java@v5
id: java
with:
java-version: 11
java-version: 21
distribution: 'temurin'
cache: 'maven'
overwrite-settings: false
Expand Down Expand Up @@ -71,7 +71,7 @@ jobs:

- uses: actions/setup-java@v5
with:
java-version: 11
java-version: 21
distribution: 'temurin'
cache: 'maven'
overwrite-settings: false
Expand Down Expand Up @@ -158,7 +158,7 @@ jobs:

- uses: actions/setup-java@v5
with:
java-version: 11
java-version: 21
distribution: 'temurin'
cache: 'maven'
overwrite-settings: false
Expand Down Expand Up @@ -190,7 +190,7 @@ jobs:

- uses: actions/setup-java@v5
with:
java-version: 11
java-version: 21
distribution: 'temurin'
cache: 'maven'
overwrite-settings: false
Expand Down
6 changes: 3 additions & 3 deletions .settings/org.eclipse.jdt.core.prefs
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,9 @@ org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
org.eclipse.jdt.core.compiler.codegen.lambda.genericSignature=do not generate
org.eclipse.jdt.core.compiler.codegen.methodParameters=generate
org.eclipse.jdt.core.compiler.codegen.shareCommonFinallyBlocks=disabled
org.eclipse.jdt.core.compiler.codegen.targetPlatform=11
org.eclipse.jdt.core.compiler.codegen.targetPlatform=21
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
org.eclipse.jdt.core.compiler.compliance=11
org.eclipse.jdt.core.compiler.compliance=21
org.eclipse.jdt.core.compiler.debug.lineNumber=generate
org.eclipse.jdt.core.compiler.debug.localVariable=generate
org.eclipse.jdt.core.compiler.debug.sourceFile=generate
Expand Down Expand Up @@ -169,7 +169,7 @@ org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning
org.eclipse.jdt.core.compiler.processAnnotations=disabled
org.eclipse.jdt.core.compiler.release=enabled
org.eclipse.jdt.core.compiler.source=11
org.eclipse.jdt.core.compiler.source=21
org.eclipse.jdt.core.compiler.storeAnnotations=disabled
org.eclipse.jdt.core.compiler.taskCaseSensitive=enabled
org.eclipse.jdt.core.compiler.taskPriorities=NORMAL,HIGH,NORMAL
Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
<maven-version>3.9.16</maven-version>
<exec.mainClass>org.rascalmpl.shell.RascalShell</exec.mainClass>
<rascal.test.memory>3</rascal.test.memory>
<maven.compiler.release>11</maven.compiler.release>
<maven.compiler.release>21</maven.compiler.release>
<rascal-maven.version>0.32.2</rascal-maven.version>
<jline.version>3.29.0</jline.version> <!-- do not upgrade unless https://github.com/jline/jline3/issues/1445 is solved-->
</properties>
Expand Down
2 changes: 1 addition & 1 deletion src/org/rascalmpl/interpreter/utils/JavaBridge.java
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ public void compileJava(ISourceLocation loc, String className, String source, Ou
public <T> Class<T> compileJava(ISourceLocation loc, String className, Class<?> parent, String source) {
try {
// watch out, if you start sharing this compiler, classes will not be able to reload
List<String> commandline = Arrays.asList(new String[] {"-proc:none", "--release", "11" });
List<String> commandline = Arrays.asList(new String[] {"-proc:none", "--release", "21" });
JavaCompiler<T> javaCompiler = new JavaCompiler<T>(parent.getClassLoader(), null, commandline);
Class<T> result = javaCompiler.compile(className, source, null, Object.class);
return result;
Expand Down
18 changes: 9 additions & 9 deletions src/org/rascalmpl/library/Prelude.java
Original file line number Diff line number Diff line change
Expand Up @@ -2571,7 +2571,7 @@ protected IValue implode(TypeStore store, Type type, IConstructor arg0, boolean

if (TreeAdapter.isLexical(tree)) {
java.lang.String constructorName = unescapedConsName(tree);
java.lang.String yield = TreeAdapter.yield(tree);
java.lang.String yielded = TreeAdapter.yield(tree);
if (constructorName != null) {
// make a single argument constructor with yield as argument
// if there is a singleton constructor with a str argument
Expand All @@ -2580,7 +2580,7 @@ protected IValue implode(TypeStore store, Type type, IConstructor arg0, boolean
}

if (isUntypedNodeType(type)) {
return values.node(constructorName, values.string(yield));
return values.node(constructorName, values.string(yielded));
}

Set<Type> conses = findConstructors(type, constructorName, 1, store);
Expand All @@ -2590,7 +2590,7 @@ protected IValue implode(TypeStore store, Type type, IConstructor arg0, boolean
@SuppressWarnings("unused")
Type cons = iter.next();
ISourceLocation loc = TreeAdapter.getLocation(tree);
IConstructor ast = makeConstructor(store, type, constructorName, values.string(yield));
IConstructor ast = makeConstructor(store, type, constructorName, values.string(yielded));
String locLabel = store.getKeywordParameterType(type, "location") == TypeFactory.getInstance().sourceLocationType() ?
"location" : "src";

Expand All @@ -2605,23 +2605,23 @@ protected IValue implode(TypeStore store, Type type, IConstructor arg0, boolean
throw failReason != null ? failReason : new Backtrack(RuntimeExceptionFactory.illegalArgument(tree, "Cannot find a matching constructor " + constructorName + " for lexical type " + type));
}
if (type.isInteger()) {
return values.integer(yield);
return values.integer(yielded);
}
if (type.isReal()) {
return values.real(yield);
return values.real(yielded);
}
if (type.isBool()) {
if (yield.equals("true")) {
if (yielded.equals("true")) {
return values.bool(true);
}
if (yield.equals("false")) {
if (yielded.equals("false")) {
return values.bool(false);
}
throw new Backtrack(RuntimeExceptionFactory.illegalArgument(tree, "Bool type does not match with " + yield));
throw new Backtrack(RuntimeExceptionFactory.illegalArgument(tree, "Bool type does not match with " + yielded));
}
if (type.isString() || isUntypedNodeType(type)) {
// NB: in "node space" all lexicals become strings
return values.string(yield);
return values.string(yielded);
}

throw RuntimeExceptionFactory.illegalArgument(tree, "Missing lexical constructor");
Expand Down
2 changes: 1 addition & 1 deletion src/org/rascalmpl/library/util/Reflective.rsc
Original file line number Diff line number Diff line change
Expand Up @@ -525,7 +525,7 @@ private str pomXml(str name, str group, str version, str rascalSrcRoot)
' \<version\>3.8.0\</version\>
' \<configuration\>
' \<compilerArgument\>-parameters\</compilerArgument\>
' \<release\>11\</release\>
' \<release\>21\</release\>
' \</configuration\>
' \</plugin\>
' \<plugin\>
Expand Down
4 changes: 2 additions & 2 deletions src/org/rascalmpl/values/parsetrees/TreeAdapter.java
Original file line number Diff line number Diff line change
Expand Up @@ -886,11 +886,11 @@ public static String yield(IConstructor tree, boolean highlight, int limit) {
}

public static String yield(IConstructor tree, int limit) {
return yield(tree, false, limit);
return TreeAdapter.yield(tree, false, limit);
}

public static String yield(IConstructor tree) {
return yield(tree, false);
return TreeAdapter.yield(tree, false);
}

public static String yield(IConstructor tree, boolean highlight) {
Expand Down
Loading