All Downloads are FREE. Search and download functionalities are using the official Maven repository.

main.seskar.compiler.value.diagnostic.ValueMessagesExtension.kt Maven / Gradle / Ivy

There is a newer version: 3.75.0
Show newest version
package seskar.compiler.value.diagnostic

import org.jetbrains.kotlin.diagnostics.rendering.DefaultErrorMessages
import org.jetbrains.kotlin.diagnostics.rendering.DiagnosticFactoryToRendererMap

private val DIAGNOSTIC_FACTORY_TO_RENDERER by lazy {
    DiagnosticFactoryToRendererMap("seskar.value").apply {
        put(
            ValueErrors.NULLABLE_JS_VALUE,
            "Nullable JS value is unsupported"
        )
        put(
            ValueErrors.INVALID_JS_VALUE_TYPE,
            "Invalid JS value type. Currently supported value types: String, Int, Double, Long"
        )
    }
}

internal object ValueMessagesExtension : DefaultErrorMessages.Extension {
    override fun getMap(): DiagnosticFactoryToRendererMap =
        DIAGNOSTIC_FACTORY_TO_RENDERER
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy