The typescript builder checks names for keywords, but it uses a list of koltin keywords instead of a list of typescript keywords:
|
// https://github.com/JetBrains/kotlin/blob/master/core/descriptors/src/org/jetbrains/kotlin/renderer/KeywordStringsGenerated.java |
|
private val KEYWORDS = setOf( |
|
"package", |
|
"as", |
|
"typealias", |
|
"class", |
|
"this", |
|
"super", |
|
"val", |
|
"var", |
|
"fun", |
|
"for", |
|
"null", |
|
"true", |
|
"false", |
|
"is", |
|
"in", |
|
"throw", |
|
"return", |
|
"break", |
|
"continue", |
|
"object", |
|
"if", |
|
"try", |
|
"else", |
|
"while", |
|
"do", |
|
"when", |
|
"interface", |
|
"typeof" |
|
) |
The list is missing they keyword enum as an example (which is also a keyword in kotlin).
The typescript builder checks names for keywords, but it uses a list of koltin keywords instead of a list of typescript keywords:
typescriptpoet/src/main/java/io/outfoxx/typescriptpoet/Utils.kt
Lines 158 to 188 in 62d7d4b
The list is missing they keyword
enumas an example (which is also a keyword in kotlin).