Serialize built-ins to separate file .kotlin_builtins

This commit is contained in:
Alexander Udalov
2015-12-23 19:52:44 +03:00
parent 07a23cab10
commit 7592f31596
9 changed files with 2225 additions and 22 deletions
@@ -47,6 +47,8 @@ object KotlinJavascriptSerializedResourcePaths : SerializedResourcePaths {
override fun getStringTableFilePath(fqName: FqName): String =
fqName.toPath().withSepIfNotEmpty() + shortName(fqName) + "." + STRING_TABLE_FILE_EXTENSION
override fun getBuiltInsFilePath(fqName: FqName): String? = null
private fun FqName.toPath() = this.asString().replace('.', '/')
private fun String.withSepIfNotEmpty() = if (this.isEmpty()) this else this + "/"