From 66f94ba8fed9db34e6ee669fc13c4832a48964da Mon Sep 17 00:00:00 2001 From: Giovanni Date: Mon, 14 Sep 2020 16:07:05 +0200 Subject: [PATCH] format code in :parser-core --- parser-jvm/build.gradle.kts | 15 --------------- .../it/unibo/tuprolog/parser/ParsingException.kt | 11 +++++------ .../tuprolog/parser/dynamic/Associativity.kt | 2 +- 3 files changed, 6 insertions(+), 22 deletions(-) diff --git a/parser-jvm/build.gradle.kts b/parser-jvm/build.gradle.kts index c985badde..70304ab97 100644 --- a/parser-jvm/build.gradle.kts +++ b/parser-jvm/build.gradle.kts @@ -15,27 +15,12 @@ val ktFreeCompilerArgsJvm: String by project dependencies { antlr("org.antlr", "antlr4", Versions.org_antlr) - api("org.antlr", "antlr4-runtime", Versions.org_antlr) implementation(kotlin("stdlib-jdk8")) - -// testImplementation("pl.pragmatists:JUnitParams:1.1.1") -// testImplementation("junit", "junit", "4.13") testImplementation(kotlin("test-junit")) } -// -//publishing { -// publications.forEach { -// println("${project.name} publication: ${it.name}") -// } -//} -// -//components.forEach { -// println("${project.name} component: ${it.name}") -//} - configure { targetCompatibility = JavaVersion.valueOf("VERSION_1_$javaVersion") sourceCompatibility = JavaVersion.valueOf("VERSION_1_$javaVersion") diff --git a/parser-jvm/src/main/kotlin/it/unibo/tuprolog/parser/ParsingException.kt b/parser-jvm/src/main/kotlin/it/unibo/tuprolog/parser/ParsingException.kt index 3d2154c16..02b31c1f6 100644 --- a/parser-jvm/src/main/kotlin/it/unibo/tuprolog/parser/ParsingException.kt +++ b/parser-jvm/src/main/kotlin/it/unibo/tuprolog/parser/ParsingException.kt @@ -11,11 +11,10 @@ class ParsingException( override fun toString(): String { return "ParsingException{" + - "message='" + message!!.replace("\\n", "\\\\n") + '\'' + - ", line=" + line + - ", column=" + column + - ", offendingSymbol='" + offendingSymbol + '\'' + - '}' + "message='" + message!!.replace("\\n", "\\\\n") + '\'' + + ", line=" + line + + ", column=" + column + + ", offendingSymbol='" + offendingSymbol + '\'' + + '}' } - } \ No newline at end of file diff --git a/parser-jvm/src/main/kotlin/it/unibo/tuprolog/parser/dynamic/Associativity.kt b/parser-jvm/src/main/kotlin/it/unibo/tuprolog/parser/dynamic/Associativity.kt index df2c18018..f55919edc 100644 --- a/parser-jvm/src/main/kotlin/it/unibo/tuprolog/parser/dynamic/Associativity.kt +++ b/parser-jvm/src/main/kotlin/it/unibo/tuprolog/parser/dynamic/Associativity.kt @@ -1,6 +1,6 @@ package it.unibo.tuprolog.parser.dynamic -import java.util.* +import java.util.EnumSet import java.util.stream.Stream enum class Associativity {