Reverted all changes related to renaming jdkHeaders to altHeaders.
This commit is contained in:
@@ -27,7 +27,7 @@ import java.lang.reflect.Method;
|
||||
*/
|
||||
public class VarArgTest extends CodegenTestCase {
|
||||
public void testStringArray () throws InvocationTargetException, IllegalAccessException {
|
||||
createEnvironmentWithMockJdkAndIdeaAnnotations(CompilerSpecialMode.ALT_HEADERS);
|
||||
createEnvironmentWithMockJdkAndIdeaAnnotations(CompilerSpecialMode.JDK_HEADERS);
|
||||
loadText("fun test(vararg ts: String) = ts");
|
||||
// System.out.println(generateToText());
|
||||
final Method main = generateFunction();
|
||||
@@ -36,7 +36,7 @@ public class VarArgTest extends CodegenTestCase {
|
||||
}
|
||||
|
||||
public void testIntArray () throws InvocationTargetException, IllegalAccessException {
|
||||
createEnvironmentWithMockJdkAndIdeaAnnotations(CompilerSpecialMode.ALT_HEADERS);
|
||||
createEnvironmentWithMockJdkAndIdeaAnnotations(CompilerSpecialMode.JDK_HEADERS);
|
||||
loadText("fun test(vararg ts: Int) = ts");
|
||||
// System.out.println(generateToText());
|
||||
final Method main = generateFunction();
|
||||
@@ -45,7 +45,7 @@ public class VarArgTest extends CodegenTestCase {
|
||||
}
|
||||
|
||||
public void testIntArrayKotlinNoArgs () throws InvocationTargetException, IllegalAccessException {
|
||||
createEnvironmentWithMockJdkAndIdeaAnnotations(CompilerSpecialMode.ALT_HEADERS);
|
||||
createEnvironmentWithMockJdkAndIdeaAnnotations(CompilerSpecialMode.JDK_HEADERS);
|
||||
loadText("fun test() = testf(); fun testf(vararg ts: Int) = ts");
|
||||
// System.out.println(generateToText());
|
||||
final Method main = generateFunction("test");
|
||||
@@ -54,7 +54,7 @@ public class VarArgTest extends CodegenTestCase {
|
||||
}
|
||||
|
||||
public void testIntArrayKotlin () throws InvocationTargetException, IllegalAccessException {
|
||||
createEnvironmentWithMockJdkAndIdeaAnnotations(CompilerSpecialMode.ALT_HEADERS);
|
||||
createEnvironmentWithMockJdkAndIdeaAnnotations(CompilerSpecialMode.JDK_HEADERS);
|
||||
loadText("fun test() = testf(239, 7); fun testf(vararg ts: Int) = ts");
|
||||
// System.out.println(generateToText());
|
||||
final Method main = generateFunction("test");
|
||||
@@ -65,7 +65,7 @@ public class VarArgTest extends CodegenTestCase {
|
||||
}
|
||||
|
||||
public void testNullableIntArrayKotlin () throws InvocationTargetException, IllegalAccessException {
|
||||
createEnvironmentWithMockJdkAndIdeaAnnotations(CompilerSpecialMode.ALT_HEADERS);
|
||||
createEnvironmentWithMockJdkAndIdeaAnnotations(CompilerSpecialMode.JDK_HEADERS);
|
||||
loadText("fun test() = testf(239.toByte(), 7.toByte()); fun testf(vararg ts: Byte?) = ts");
|
||||
// System.out.println(generateToText());
|
||||
final Method main = generateFunction("test");
|
||||
@@ -76,7 +76,7 @@ public class VarArgTest extends CodegenTestCase {
|
||||
}
|
||||
|
||||
public void testIntArrayKotlinObj () throws InvocationTargetException, IllegalAccessException {
|
||||
createEnvironmentWithMockJdkAndIdeaAnnotations(CompilerSpecialMode.ALT_HEADERS);
|
||||
createEnvironmentWithMockJdkAndIdeaAnnotations(CompilerSpecialMode.JDK_HEADERS);
|
||||
loadText("fun test() = testf(\"239\"); fun testf(vararg ts: String) = ts");
|
||||
// System.out.println(generateToText());
|
||||
final Method main = generateFunction("test");
|
||||
@@ -86,7 +86,7 @@ public class VarArgTest extends CodegenTestCase {
|
||||
}
|
||||
|
||||
public void testArrayT () throws InvocationTargetException, IllegalAccessException {
|
||||
createEnvironmentWithMockJdkAndIdeaAnnotations(CompilerSpecialMode.ALT_HEADERS);
|
||||
createEnvironmentWithMockJdkAndIdeaAnnotations(CompilerSpecialMode.JDK_HEADERS);
|
||||
loadText("fun test() = _array(2, 4); fun <T> _array(vararg elements : T) = elements");
|
||||
// System.out.println(generateToText());
|
||||
final Method main = generateFunction("test");
|
||||
@@ -102,12 +102,12 @@ public class VarArgTest extends CodegenTestCase {
|
||||
}
|
||||
|
||||
public void testKt797() {
|
||||
createEnvironmentWithMockJdkAndIdeaAnnotations(CompilerSpecialMode.ALT_HEADERS);
|
||||
createEnvironmentWithMockJdkAndIdeaAnnotations(CompilerSpecialMode.JDK_HEADERS);
|
||||
blackBoxFile("regressions/kt796_797.jet");
|
||||
}
|
||||
|
||||
public void testArrayAsVararg () throws InvocationTargetException, IllegalAccessException {
|
||||
createEnvironmentWithMockJdkAndIdeaAnnotations(CompilerSpecialMode.ALT_HEADERS);
|
||||
createEnvironmentWithMockJdkAndIdeaAnnotations(CompilerSpecialMode.JDK_HEADERS);
|
||||
loadText("private fun asList(vararg elems: String) = elems; fun test(ts: Array<String>) = asList(*ts); ");
|
||||
//System.out.println(generateToText());
|
||||
final Method main = generateFunction("test");
|
||||
@@ -116,7 +116,7 @@ public class VarArgTest extends CodegenTestCase {
|
||||
}
|
||||
|
||||
public void testArrayAsVararg2 () throws InvocationTargetException, IllegalAccessException {
|
||||
createEnvironmentWithMockJdkAndIdeaAnnotations(CompilerSpecialMode.ALT_HEADERS);
|
||||
createEnvironmentWithMockJdkAndIdeaAnnotations(CompilerSpecialMode.JDK_HEADERS);
|
||||
loadText("private fun asList(vararg elems: String) = elems; fun test(ts1: Array<String>, ts2: String) = asList(*ts1, ts2); ");
|
||||
System.out.println(generateToText());
|
||||
final Method main = generateFunction("test");
|
||||
|
||||
Reference in New Issue
Block a user