Configuration: Don't create kotlinc.xml if the settings don't differ from the defaults

#KT-16647 Fixed

Original commit: 6b6d7a5030
This commit is contained in:
Alexey Sedunov
2017-03-09 15:37:28 +03:00
parent f936dea850
commit 6ea2a6540f
@@ -23,7 +23,7 @@ import org.jdom.Element
import org.jetbrains.kotlin.cli.common.arguments.K2JSCompilerArguments
import org.jetbrains.kotlin.cli.common.arguments.K2JVMCompilerArguments
private fun Element.getOption(name: String) = getChildren("option").firstOrNull { it.getAttribute("name").value == name }
fun Element.getOption(name: String) = getChildren("option").firstOrNull { it.getAttribute("name").value == name }
private fun Element.getOptionValue(name: String) = getOption(name)?.getAttribute("value")?.value