Change built-ins generators package from 'runtime' to 'builtins'
This commit is contained in:
+5
-7
@@ -14,7 +14,7 @@
|
|||||||
* limitations under the License.
|
* limitations under the License.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package org.jetbrains.jet.generators.runtime;
|
package org.jetbrains.jet.generators.builtins;
|
||||||
|
|
||||||
import com.intellij.openapi.util.io.FileUtil;
|
import com.intellij.openapi.util.io.FileUtil;
|
||||||
|
|
||||||
@@ -25,7 +25,7 @@ import java.io.PrintStream;
|
|||||||
import java.util.Arrays;
|
import java.util.Arrays;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
public class GenerateRanges {
|
public class GenerateRangeIntrinsics {
|
||||||
private static String castIfNecessary(String what, String thisType, String otherType) {
|
private static String castIfNecessary(String what, String thisType, String otherType) {
|
||||||
if (thisType.equals("byte") && otherType.equals("char") || thisType.equals("char") && otherType.equals("short")) {
|
if (thisType.equals("byte") && otherType.equals("char") || thisType.equals("char") && otherType.equals("short")) {
|
||||||
return "(" + otherType + ") " + what;
|
return "(" + otherType + ") " + what;
|
||||||
@@ -34,7 +34,7 @@ public class GenerateRanges {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public static void main(String[] args) throws IOException {
|
public static void main(String[] args) throws IOException {
|
||||||
PrintStream out = new PrintStream(new FileOutputStream("runtime/src/jet/runtime/Ranges.java"));
|
PrintStream out = new PrintStream(new FileOutputStream("core/runtime.jvm/src/jet/runtime/Ranges.java"));
|
||||||
try {
|
try {
|
||||||
String copyright = "injector-generator/copyright.txt";
|
String copyright = "injector-generator/copyright.txt";
|
||||||
out.println(FileUtil.loadFile(new File(copyright)));
|
out.println(FileUtil.loadFile(new File(copyright)));
|
||||||
@@ -46,7 +46,7 @@ public class GenerateRanges {
|
|||||||
out.println("import jet.*;");
|
out.println("import jet.*;");
|
||||||
out.println();
|
out.println();
|
||||||
|
|
||||||
out.println("/* This file is generated by " + GenerateRanges.class.getName() + ". DO NOT EDIT! */");
|
out.println("/* This file is generated by " + GenerateRangeIntrinsics.class.getName() + ". DO NOT EDIT! */");
|
||||||
out.println("public class Ranges {");
|
out.println("public class Ranges {");
|
||||||
|
|
||||||
List<String> strings = Arrays.asList("byte", "short", "int", "long", "float", "double", "char");
|
List<String> strings = Arrays.asList("byte", "short", "int", "long", "float", "double", "char");
|
||||||
@@ -95,10 +95,8 @@ public class GenerateRanges {
|
|||||||
finally {
|
finally {
|
||||||
out.close();
|
out.close();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private GenerateRanges() {
|
private GenerateRangeIntrinsics() {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
+2
-2
@@ -14,12 +14,12 @@
|
|||||||
* limitations under the License.
|
* limitations under the License.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package org.jetbrains.jet.generators.runtime
|
package org.jetbrains.jet.generators.builtins
|
||||||
|
|
||||||
import java.io.File
|
import java.io.File
|
||||||
import kotlin.properties.Delegates
|
import kotlin.properties.Delegates
|
||||||
import java.io.PrintWriter
|
import java.io.PrintWriter
|
||||||
import org.jetbrains.jet.generators.runtime.ProgressionKind.*
|
import org.jetbrains.jet.generators.builtins.ProgressionKind.*
|
||||||
|
|
||||||
enum class ProgressionKind {
|
enum class ProgressionKind {
|
||||||
BYTE
|
BYTE
|
||||||
+3
-3
@@ -14,11 +14,11 @@
|
|||||||
* limitations under the License.
|
* limitations under the License.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package org.jetbrains.jet.generators.runtime.functions
|
package org.jetbrains.jet.generators.builtins.functions
|
||||||
|
|
||||||
import java.io.PrintWriter
|
import java.io.PrintWriter
|
||||||
import org.jetbrains.jet.generators.runtime.functions.FunctionKind.*
|
import org.jetbrains.jet.generators.builtins.functions.FunctionKind.*
|
||||||
import org.jetbrains.jet.generators.runtime.*
|
import org.jetbrains.jet.generators.builtins.*
|
||||||
|
|
||||||
val MAX_PARAM_COUNT = 22
|
val MAX_PARAM_COUNT = 22
|
||||||
|
|
||||||
+2
-2
@@ -14,9 +14,9 @@
|
|||||||
* limitations under the License.
|
* limitations under the License.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package org.jetbrains.jet.generators.runtime.iterators
|
package org.jetbrains.jet.generators.builtins.iterators
|
||||||
|
|
||||||
import org.jetbrains.jet.generators.runtime.*
|
import org.jetbrains.jet.generators.builtins.*
|
||||||
import java.io.PrintWriter
|
import java.io.PrintWriter
|
||||||
|
|
||||||
enum class IteratorKind {
|
enum class IteratorKind {
|
||||||
+3
-3
@@ -14,10 +14,10 @@
|
|||||||
* limitations under the License.
|
* limitations under the License.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package org.jetbrains.jet.generators.runtime.progressionIterators
|
package org.jetbrains.jet.generators.builtins.progressionIterators
|
||||||
|
|
||||||
import org.jetbrains.jet.generators.runtime.*
|
import org.jetbrains.jet.generators.builtins.*
|
||||||
import org.jetbrains.jet.generators.runtime.ProgressionKind.*
|
import org.jetbrains.jet.generators.builtins.ProgressionKind.*
|
||||||
import java.io.PrintWriter
|
import java.io.PrintWriter
|
||||||
|
|
||||||
fun integerProgressionIterator(kind: ProgressionKind): String {
|
fun integerProgressionIterator(kind: ProgressionKind): String {
|
||||||
+3
-3
@@ -14,10 +14,10 @@
|
|||||||
* limitations under the License.
|
* limitations under the License.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package org.jetbrains.jet.generators.runtime.progressions
|
package org.jetbrains.jet.generators.builtins.progressions
|
||||||
|
|
||||||
import org.jetbrains.jet.generators.runtime.*
|
import org.jetbrains.jet.generators.builtins.*
|
||||||
import org.jetbrains.jet.generators.runtime.ProgressionKind.*
|
import org.jetbrains.jet.generators.builtins.ProgressionKind.*
|
||||||
import java.io.PrintWriter
|
import java.io.PrintWriter
|
||||||
|
|
||||||
class GenerateProgressions(val out: PrintWriter) {
|
class GenerateProgressions(val out: PrintWriter) {
|
||||||
+3
-3
@@ -14,10 +14,10 @@
|
|||||||
* limitations under the License.
|
* limitations under the License.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package org.jetbrains.jet.generators.runtime.ranges
|
package org.jetbrains.jet.generators.builtins.ranges
|
||||||
|
|
||||||
import org.jetbrains.jet.generators.runtime.*
|
import org.jetbrains.jet.generators.builtins.*
|
||||||
import org.jetbrains.jet.generators.runtime.ProgressionKind.*
|
import org.jetbrains.jet.generators.builtins.ProgressionKind.*
|
||||||
import java.io.PrintWriter
|
import java.io.PrintWriter
|
||||||
|
|
||||||
class GenerateRanges(val out: PrintWriter) {
|
class GenerateRanges(val out: PrintWriter) {
|
||||||
Reference in New Issue
Block a user