Skip to content

Commit 86f0f2e

Browse files
committed
Fix return types
1 parent dd0513f commit 86f0f2e

2 files changed

Lines changed: 18 additions & 31 deletions

File tree

.idea/workspace.xml

Lines changed: 17 additions & 26 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/main/kotlin/generator/LuaEmitter.kt

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -43,11 +43,7 @@ class LuaEmitter {
4343
sb.appendLine("---@param $paramName${if (!param.required) "?" else ""} $luaType ${param.comment ?: ""}")
4444
}
4545

46-
if (!doc.returnComment.isNullOrBlank()) {
47-
sb.appendLine("---@return ${mapJavaTypeToLua(method.returnType)} ${doc.returnComment}")
48-
} else {
49-
sb.appendLine("---@return nil")
50-
}
46+
sb.appendLine("---@return ${mapJavaTypeToLua(method.returnType)} ${doc.returnComment ?: ""}")
5147

5248
if (doc.mainComment.isNotBlank()) {
5349
sb.appendLine("--- ${doc.mainComment}")

0 commit comments

Comments
 (0)