diff --git a/.idea/kotlinc.xml b/.idea/kotlinc.xml index 8d81632..6d0ee1c 100644 --- a/.idea/kotlinc.xml +++ b/.idea/kotlinc.xml @@ -1,6 +1,6 @@ - \ No newline at end of file diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index 897d7b1..e88bafa 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -4,12 +4,12 @@ [versions] guava = "32.1.2-jre" gson = "2.9.1" -jmlparser = "3.25.10-b3-SNAPSHOT" +jmlparser = "3.25.10-b5-SNAPSHOT" logback = "1.4.12" jupiter = "5.12.0" clickt = "4.2.2" jdk = "21" -kotlin = "1.9.20" +kotlin = "2.0.0" ktor = "2.3.11" [libraries] diff --git a/jml2java/src/main/kotlin/io/github/jmltoolkit/jml2java/Jml2JavaTranslator.kt b/jml2java/src/main/kotlin/io/github/jmltoolkit/jml2java/Jml2JavaTranslator.kt index 89195fc..c0f2ba8 100644 --- a/jml2java/src/main/kotlin/io/github/jmltoolkit/jml2java/Jml2JavaTranslator.kt +++ b/jml2java/src/main/kotlin/io/github/jmltoolkit/jml2java/Jml2JavaTranslator.kt @@ -70,7 +70,7 @@ class Jml2JavaTranslator { if (e.operators[0] == BinaryExpr.Operator.LESS_EQUALS) return e.expressions[0] if (e.operators[0] == BinaryExpr.Operator.LESS) return BinaryExpr( e.expressions[0], - IntegerLiteralExpr(1), + IntegerLiteralExpr("1"), BinaryExpr.Operator.PLUS ) throw IllegalStateException() @@ -93,7 +93,7 @@ class Jml2JavaTranslator { val result = pattern.find(n) if (result != null) return BinaryExpr( result["min"] as Expression?, - IntegerLiteralExpr(1), + IntegerLiteralExpr("1"), BinaryExpr.Operator.PLUS ) } @@ -113,7 +113,7 @@ class Jml2JavaTranslator { val result = pattern.find(n) if (result != null) return BinaryExpr( result["min"] as Expression?, - IntegerLiteralExpr(1), + IntegerLiteralExpr("1"), BinaryExpr.Operator.PLUS ) } @@ -335,7 +335,7 @@ class Jml2JavaTranslator { ) { if (e.operators[0] == BinaryExpr.Operator.LESS_EQUALS) return e.expressions[0] if (e.operators[0] == BinaryExpr.Operator.LESS) return BinaryExpr( - e.expressions[0], IntegerLiteralExpr(1), BinaryExpr.Operator.PLUS + e.expressions[0], IntegerLiteralExpr("1"), BinaryExpr.Operator.PLUS ) throw IllegalStateException() } @@ -357,7 +357,7 @@ class Jml2JavaTranslator { val result = pattern.find(n) if (result != null) return BinaryExpr( result["min"] as Expression?, - IntegerLiteralExpr(1), + IntegerLiteralExpr("1"), BinaryExpr.Operator.PLUS ) } @@ -377,7 +377,7 @@ class Jml2JavaTranslator { val result = pattern.find(n) if (result != null) return BinaryExpr( result["min"] as Expression?, - IntegerLiteralExpr(1), + IntegerLiteralExpr("1"), BinaryExpr.Operator.PLUS ) }