default -> companion: default object -> class object in project code, builtins and libs code
This commit is contained in:
@@ -80,7 +80,7 @@ public class JsFunctionScope(parent: JsScope, description: String) : JsScope(par
|
||||
|| getParent()?.hasOwnName(name) ?: false
|
||||
}
|
||||
|
||||
default object {
|
||||
class object {
|
||||
public val RESERVED_WORDS: Set<String> = setOf(
|
||||
// keywords
|
||||
"await", "break", "case", "catch", "continue", "debugger", "default", "delete", "do", "else", "finally", "for", "function", "if",
|
||||
|
||||
@@ -28,7 +28,7 @@ public enum class PredefinedAnnotation(fqName: String) {
|
||||
|
||||
public val fqName: FqName = FqName(fqName)
|
||||
|
||||
default object {
|
||||
class object {
|
||||
// TODO: replace with straight assignment when KT-5761 will be fixed
|
||||
val WITH_CUSTOM_NAME by Delegates.lazy { setOf(LIBRARY, NATIVE) }
|
||||
}
|
||||
|
||||
@@ -28,7 +28,7 @@ public class JsAnalysisResult(
|
||||
moduleDescriptor: ModuleDescriptor
|
||||
) : AnalysisResult(bindingTrace.getBindingContext(), moduleDescriptor) {
|
||||
|
||||
default object {
|
||||
class object {
|
||||
platformStatic public fun success(trace: BindingTrace, module: ModuleDescriptor): JsAnalysisResult {
|
||||
return JsAnalysisResult(trace, module)
|
||||
}
|
||||
|
||||
@@ -50,7 +50,7 @@ import org.jetbrains.kotlin.resolve.TemporaryBindingTrace
|
||||
|
||||
public class JsCallChecker : CallChecker {
|
||||
|
||||
default object {
|
||||
class object {
|
||||
private val JS_PATTERN: DescriptorPredicate = PatternBuilder.pattern("kotlin.js.js(String)")
|
||||
|
||||
platformStatic
|
||||
|
||||
@@ -94,7 +94,7 @@ public final class AnnotationsUtils {
|
||||
}
|
||||
|
||||
for (DeclarationDescriptor descriptor : descriptors) {
|
||||
for (PredefinedAnnotation annotation : PredefinedAnnotation.Default.getWITH_CUSTOM_NAME()) {
|
||||
for (PredefinedAnnotation annotation : PredefinedAnnotation.OBJECT$.getWITH_CUSTOM_NAME()) {
|
||||
if (!hasAnnotationOrInsideAnnotatedClass(descriptor, annotation)) {
|
||||
continue;
|
||||
}
|
||||
|
||||
@@ -93,7 +93,7 @@ native public trait DOMError {
|
||||
public val severity: Short
|
||||
public val type: String
|
||||
|
||||
public default object {
|
||||
public class object {
|
||||
public val SEVERITY_ERROR: Short = 2
|
||||
public val SEVERITY_FATAL_ERROR: Short = 3
|
||||
public val SEVERITY_WARNING: Short = 1
|
||||
@@ -221,7 +221,7 @@ native public trait Node {
|
||||
public fun replaceChild(arg1: Node, arg2: Node): Node = noImpl
|
||||
public fun setUserData(arg1: String?, arg2: Any, arg3: UserDataHandler): Any = noImpl
|
||||
|
||||
public default object {
|
||||
public class object {
|
||||
public val ATTRIBUTE_NODE: Short = 2
|
||||
public val CDATA_SECTION_NODE: Short = 4
|
||||
public val COMMENT_NODE: Short = 8
|
||||
@@ -270,7 +270,7 @@ native public trait TypeInfo {
|
||||
public val typeNamespace: String
|
||||
public fun isDerivedFrom(arg1: String?, arg2: String?, arg3: Int): Boolean = noImpl
|
||||
|
||||
public default object {
|
||||
public class object {
|
||||
public val DERIVATION_EXTENSION: Int = 2
|
||||
public val DERIVATION_LIST: Int = 8
|
||||
public val DERIVATION_RESTRICTION: Int = 1
|
||||
@@ -281,7 +281,7 @@ native public trait TypeInfo {
|
||||
native public trait UserDataHandler {
|
||||
public fun handle(arg1: Short, arg2: String?, arg3: Any, arg4: Node, arg5: Node): Unit = noImpl
|
||||
|
||||
public default object {
|
||||
public class object {
|
||||
public val NODE_ADOPTED: Short = 5
|
||||
public val NODE_CLONED: Short = 1
|
||||
public val NODE_DELETED: Short = 3
|
||||
|
||||
@@ -29,7 +29,7 @@ native public trait Event {
|
||||
public fun preventDefault(): Unit = noImpl
|
||||
public fun stopPropagation(): Unit = noImpl
|
||||
|
||||
public default object {
|
||||
public class object {
|
||||
public val AT_TARGET: Short = 2
|
||||
public val BUBBLING_PHASE: Short = 3
|
||||
public val CAPTURING_PHASE: Short = 1
|
||||
@@ -64,7 +64,7 @@ native public trait MutationEvent: Event {
|
||||
public val relatedNode: Node
|
||||
public fun initMutationEvent(arg1: String?, arg2: Boolean, arg3: Boolean, arg4: Node, arg5: String?, arg6: String?, arg7: String?, arg8: Short): Unit = noImpl
|
||||
|
||||
public default object {
|
||||
public class object {
|
||||
public val ADDITION: Short = 2
|
||||
public val MODIFICATION: Short = 1
|
||||
public val REMOVAL: Short = 3
|
||||
|
||||
@@ -31,7 +31,7 @@ public class InlineMetadata(
|
||||
val function: JsFunction,
|
||||
val endTag: JsStringLiteral
|
||||
) {
|
||||
default object {
|
||||
class object {
|
||||
platformStatic
|
||||
fun compose(function: JsFunction, descriptor: CallableDescriptor): InlineMetadata {
|
||||
val program = function.getScope().getProgram()
|
||||
|
||||
Reference in New Issue
Block a user