From 38401d04d5e0a3005e89147c82853fe9764c3e72 Mon Sep 17 00:00:00 2001 From: Zalim Bashorov Date: Tue, 16 Sep 2014 17:06:24 +0400 Subject: [PATCH] Minor: made noImpl generic to avoid using in wrong context. --- js/js.libraries/src/core/core.kt | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/js/js.libraries/src/core/core.kt b/js/js.libraries/src/core/core.kt index 914be0651c2..df7d7e05e7a 100644 --- a/js/js.libraries/src/core/core.kt +++ b/js/js.libraries/src/core/core.kt @@ -3,7 +3,7 @@ package kotlin.js import java.util.*; native -public val noImpl : Nothing = throw Exception() +public val noImpl: T = throw Exception() // Drop this after KT-2093 will be fixed and restore MutableMap.set in Maps.kt from MapsJVM.kt /** Provides [] access to maps */ @@ -17,8 +17,8 @@ public fun println(s : Any?) {} library("print") public fun print(s : Any?) {} //TODO: consistent parseInt -native public fun parseInt(s: String, radix: Int = 10): Int = js.noImpl +native public fun parseInt(s: String, radix: Int = 10): Int = noImpl library -public fun safeParseInt(s : String) : Int? = js.noImpl +public fun safeParseInt(s : String) : Int? = noImpl library -public fun safeParseDouble(s : String) : Double? = js.noImpl +public fun safeParseDouble(s : String) : Double? = noImpl