Deprecated 'INSTANCE$' replaced with 'INSTANCE'
This commit is contained in:
@@ -46,8 +46,8 @@ public final class Namer {
|
||||
public static final JsNameRef KOTLIN_OBJECT_REF = new JsNameRef(KOTLIN_NAME);
|
||||
public static final JsNameRef KOTLIN_LONG_NAME_REF = new JsNameRef("Long", KOTLIN_OBJECT_REF);
|
||||
|
||||
public static final String EQUALS_METHOD_NAME = getStableMangledNameForDescriptor(JsPlatform.INSTANCE$.getBuiltIns().getAny(), "equals");
|
||||
public static final String COMPARE_TO_METHOD_NAME = getStableMangledNameForDescriptor(JsPlatform.INSTANCE$.getBuiltIns().getComparable(), "compareTo");
|
||||
public static final String EQUALS_METHOD_NAME = getStableMangledNameForDescriptor(JsPlatform.INSTANCE.getBuiltIns().getAny(), "equals");
|
||||
public static final String COMPARE_TO_METHOD_NAME = getStableMangledNameForDescriptor(JsPlatform.INSTANCE.getBuiltIns().getComparable(), "compareTo");
|
||||
public static final String NUMBER_RANGE = "NumberRange";
|
||||
public static final String CHAR_RANGE = "CharRange";
|
||||
public static final String LONG_FROM_NUMBER = "fromNumber";
|
||||
|
||||
@@ -243,7 +243,7 @@ public final class StaticContext {
|
||||
public JsName apply(@NotNull DeclarationDescriptor descriptor) {
|
||||
if (isDynamic(descriptor)) {
|
||||
String name = descriptor.getName().asString();
|
||||
return JsDynamicScope.INSTANCE$.declareName(name);
|
||||
return JsDynamicScope.INSTANCE.declareName(name);
|
||||
}
|
||||
|
||||
return null;
|
||||
|
||||
+2
-2
@@ -159,7 +159,7 @@ public final class ExpressionVisitor extends TranslatorVisitor<JsNode> {
|
||||
if (expressionInside != null) {
|
||||
return Translation.translateExpression(expressionInside, context);
|
||||
}
|
||||
return JsEmpty.INSTANCE$;
|
||||
return JsEmpty.INSTANCE;
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -191,7 +191,7 @@ public final class ExpressionVisitor extends TranslatorVisitor<JsNode> {
|
||||
@Override
|
||||
@NotNull
|
||||
public JsNode visitCallableReferenceExpression(@NotNull KtCallableReferenceExpression expression, @NotNull TranslationContext context) {
|
||||
return CallableReferenceTranslator.INSTANCE$.translate(expression, context);
|
||||
return CallableReferenceTranslator.INSTANCE.translate(expression, context);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
+1
-1
@@ -63,7 +63,7 @@ public final class WhenTranslator extends AbstractTranslator {
|
||||
|
||||
private JsStatement translate() {
|
||||
if (expressionToMatch != null && JsAstUtils.isEmptyExpression(expressionToMatch)) {
|
||||
return JsEmpty.INSTANCE$;
|
||||
return JsEmpty.INSTANCE;
|
||||
}
|
||||
|
||||
JsIf currentIf = null;
|
||||
|
||||
@@ -232,6 +232,6 @@ public final class Translation {
|
||||
}
|
||||
FunctionDescriptor functionDescriptor = getFunctionDescriptor(context.bindingContext(), mainFunction);
|
||||
JsArrayLiteral argument = new JsArrayLiteral(toStringLiteralList(arguments, context.program()));
|
||||
return CallTranslator.INSTANCE$.buildCall(context, functionDescriptor, Collections.singletonList(argument), null).makeStmt();
|
||||
return CallTranslator.INSTANCE.buildCall(context, functionDescriptor, Collections.singletonList(argument), null).makeStmt();
|
||||
}
|
||||
}
|
||||
|
||||
+2
-2
@@ -40,13 +40,13 @@ public final class FunctionIntrinsics {
|
||||
}
|
||||
|
||||
private void registerFactories() {
|
||||
register(LongOperationFIF.INSTANCE$);
|
||||
register(LongOperationFIF.INSTANCE);
|
||||
register(PrimitiveUnaryOperationFIF.INSTANCE);
|
||||
register(PrimitiveBinaryOperationFIF.INSTANCE);
|
||||
register(StringOperationFIF.INSTANCE);
|
||||
register(ArrayFIF.INSTANCE);
|
||||
register(TopLevelFIF.INSTANCE);
|
||||
register(NumberAndCharConversionFIF.INSTANCE$);
|
||||
register(NumberAndCharConversionFIF.INSTANCE);
|
||||
register(ProgressionCompanionFIF.INSTANCE);
|
||||
}
|
||||
|
||||
|
||||
+1
-1
@@ -200,7 +200,7 @@ public final class TopLevelFIF extends CompositeFIF {
|
||||
}
|
||||
}
|
||||
|
||||
String mangledName = getStableMangledNameForDescriptor(JsPlatform.INSTANCE$.getBuiltIns().getMutableMap(), operationName());
|
||||
String mangledName = getStableMangledNameForDescriptor(JsPlatform.INSTANCE.getBuiltIns().getMutableMap(), operationName());
|
||||
|
||||
return new JsInvocation(new JsNameRef(mangledName, thisOrReceiver), arguments);
|
||||
}
|
||||
|
||||
+1
-1
@@ -131,6 +131,6 @@ public final class CallExpressionTranslator extends AbstractCallExpressionTransl
|
||||
assert currentScope instanceof JsFunctionScope : "Usage of js outside of function is unexpected";
|
||||
JsScope temporaryRootScope = new JsRootScope(new JsProgram("<js code>"));
|
||||
JsScope scope = new DelegatingJsFunctionScopeWithTemporaryParent((JsFunctionScope) currentScope, temporaryRootScope);
|
||||
return ParserUtilsKt.parse(jsCode, ThrowExceptionOnErrorReporter.INSTANCE$, scope);
|
||||
return ParserUtilsKt.parse(jsCode, ThrowExceptionOnErrorReporter.INSTANCE, scope);
|
||||
}
|
||||
}
|
||||
|
||||
+2
-2
@@ -63,13 +63,13 @@ public class VariableAccessTranslator extends AbstractTranslator implements Acce
|
||||
@NotNull
|
||||
@Override
|
||||
public JsExpression translateAsGet() {
|
||||
return CallTranslator.INSTANCE$.translateGet(context(), resolvedCall, receiver);
|
||||
return CallTranslator.INSTANCE.translateGet(context(), resolvedCall, receiver);
|
||||
}
|
||||
|
||||
@NotNull
|
||||
@Override
|
||||
public JsExpression translateAsSet(@NotNull JsExpression setTo) {
|
||||
return CallTranslator.INSTANCE$.translateSet(context(), resolvedCall, setTo, receiver);
|
||||
return CallTranslator.INSTANCE.translateSet(context(), resolvedCall, setTo, receiver);
|
||||
}
|
||||
|
||||
@NotNull
|
||||
|
||||
@@ -60,7 +60,7 @@ public final class JSTestGenerator {
|
||||
@NotNull ClassDescriptor classDescriptor, @NotNull JSTester tester) {
|
||||
JsExpression expression = ReferenceTranslator.translateAsFQReference(classDescriptor, context);
|
||||
JsNew testClass = new JsNew(expression);
|
||||
JsExpression functionToTestCall = CallTranslator.INSTANCE$.buildCall(context, functionDescriptor,
|
||||
JsExpression functionToTestCall = CallTranslator.INSTANCE.buildCall(context, functionDescriptor,
|
||||
Collections.<JsExpression>emptyList(), testClass);
|
||||
JsStringLiteral testName = context.program().getStringLiteral(classDescriptor.getName() + "." + functionDescriptor.getName());
|
||||
tester.constructTestMethodInvocation(functionToTestCall, testName);
|
||||
|
||||
Reference in New Issue
Block a user