Temporary hack to migrate functions to package kotlin.jvm.functions
Add a file in package 'kotlin.jvm.functions' to the project and replace
explicit imports of functions 'kotlin.Function{n}' to two imports 'kotlin.*'
and 'kotlin.jvm.functions.*', so that the codebase can be compiled both by the
old and by the new compiler
This commit is contained in:
+2
-1
@@ -16,7 +16,8 @@
|
||||
|
||||
package org.jetbrains.kotlin.load.java.components;
|
||||
|
||||
import kotlin.Function1;
|
||||
import kotlin.jvm.functions.*;
|
||||
import kotlin.*;
|
||||
import kotlin.Unit;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
|
||||
+2
-1
@@ -16,7 +16,8 @@
|
||||
|
||||
package org.jetbrains.kotlin.load.kotlin;
|
||||
|
||||
import kotlin.Function0;
|
||||
import kotlin.jvm.functions.*;
|
||||
import kotlin.*;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
import org.jetbrains.kotlin.descriptors.ClassDescriptor;
|
||||
|
||||
@@ -16,7 +16,8 @@
|
||||
|
||||
package org.jetbrains.kotlin.builtins;
|
||||
|
||||
import kotlin.Function1;
|
||||
import kotlin.jvm.functions.*;
|
||||
import kotlin.*;
|
||||
import kotlin.KotlinPackage;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
|
||||
+2
-1
@@ -16,7 +16,8 @@
|
||||
|
||||
package org.jetbrains.kotlin.descriptors.impl;
|
||||
|
||||
import kotlin.Function0;
|
||||
import kotlin.jvm.functions.*;
|
||||
import kotlin.*;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.kotlin.descriptors.*;
|
||||
import org.jetbrains.kotlin.name.Name;
|
||||
|
||||
+2
-1
@@ -16,7 +16,8 @@
|
||||
|
||||
package org.jetbrains.kotlin.descriptors.impl;
|
||||
|
||||
import kotlin.Function0;
|
||||
import kotlin.jvm.functions.*;
|
||||
import kotlin.*;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.annotations.ReadOnly;
|
||||
import org.jetbrains.kotlin.builtins.KotlinBuiltIns;
|
||||
|
||||
+4
-2
@@ -16,8 +16,10 @@
|
||||
|
||||
package org.jetbrains.kotlin.descriptors.impl;
|
||||
|
||||
import kotlin.Function0;
|
||||
import kotlin.Function1;
|
||||
import kotlin.jvm.functions.*;
|
||||
import kotlin.*;
|
||||
import kotlin.jvm.functions.*;
|
||||
import kotlin.*;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
import org.jetbrains.kotlin.descriptors.*;
|
||||
|
||||
@@ -16,7 +16,8 @@
|
||||
|
||||
package org.jetbrains.kotlin.renderer;
|
||||
|
||||
import kotlin.Function1;
|
||||
import kotlin.jvm.functions.*;
|
||||
import kotlin.*;
|
||||
import kotlin.KotlinPackage;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.kotlin.name.FqName;
|
||||
|
||||
@@ -16,7 +16,8 @@
|
||||
|
||||
package org.jetbrains.kotlin.renderer;
|
||||
|
||||
import kotlin.Function1;
|
||||
import kotlin.jvm.functions.*;
|
||||
import kotlin.*;
|
||||
import kotlin.KotlinPackage;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
|
||||
@@ -16,7 +16,8 @@
|
||||
|
||||
package org.jetbrains.kotlin.resolve;
|
||||
|
||||
import kotlin.Function1;
|
||||
import kotlin.jvm.functions.*;
|
||||
import kotlin.*;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
import org.jetbrains.kotlin.builtins.KotlinBuiltIns;
|
||||
|
||||
@@ -16,7 +16,8 @@
|
||||
|
||||
package org.jetbrains.kotlin.resolve;
|
||||
|
||||
import kotlin.Function1;
|
||||
import kotlin.jvm.functions.*;
|
||||
import kotlin.*;
|
||||
import kotlin.KotlinPackage;
|
||||
import kotlin.Unit;
|
||||
import kotlin.jvm.KotlinSignature;
|
||||
|
||||
@@ -16,7 +16,8 @@
|
||||
|
||||
package org.jetbrains.kotlin.types;
|
||||
|
||||
import kotlin.Function1;
|
||||
import kotlin.jvm.functions.*;
|
||||
import kotlin.*;
|
||||
import kotlin.KotlinPackage;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
|
||||
@@ -16,7 +16,8 @@
|
||||
|
||||
package org.jetbrains.kotlin.types;
|
||||
|
||||
import kotlin.Function1;
|
||||
import kotlin.jvm.functions.*;
|
||||
import kotlin.*;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
import org.jetbrains.kotlin.builtins.KotlinBuiltIns;
|
||||
|
||||
@@ -16,7 +16,8 @@
|
||||
|
||||
package org.jetbrains.kotlin.types;
|
||||
|
||||
import kotlin.Function1;
|
||||
import kotlin.jvm.functions.*;
|
||||
import kotlin.*;
|
||||
import kotlin.KotlinPackage;
|
||||
import kotlin.Unit;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
@@ -16,7 +16,8 @@
|
||||
|
||||
package kotlin.reflect.jvm.internal;
|
||||
|
||||
import kotlin.Function0;
|
||||
import kotlin.jvm.functions.*;
|
||||
import kotlin.*;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
|
||||
|
||||
@@ -0,0 +1,22 @@
|
||||
/*
|
||||
* Copyright 2010-2015 JetBrains s.r.o.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package kotlin.jvm.functions
|
||||
|
||||
/**
|
||||
* This is a hack to allow star import from the package [kotlin.jvm.functions] to allow to migrate functional types
|
||||
*/
|
||||
public object _
|
||||
@@ -16,8 +16,10 @@
|
||||
|
||||
package org.jetbrains.kotlin.storage;
|
||||
|
||||
import kotlin.Function0;
|
||||
import kotlin.Function1;
|
||||
import kotlin.jvm.functions.*;
|
||||
import kotlin.*;
|
||||
import kotlin.jvm.functions.*;
|
||||
import kotlin.*;
|
||||
import kotlin.Unit;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
|
||||
Reference in New Issue
Block a user