From 1a2629b875558e0d97b8f64acaf444bc0dfce6e0 Mon Sep 17 00:00:00 2001 From: Giorgio Garofalo Date: Wed, 9 Aug 2023 16:24:25 +0200 Subject: [PATCH] Fix missing parenthesis in string references --- .../iamgio/pikt/expression/kotlin/KotlinExpressionTranspiler.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/src/main/kotlin/eu/iamgio/pikt/expression/kotlin/KotlinExpressionTranspiler.kt b/core/src/main/kotlin/eu/iamgio/pikt/expression/kotlin/KotlinExpressionTranspiler.kt index 14b4c45..1c1e201 100644 --- a/core/src/main/kotlin/eu/iamgio/pikt/expression/kotlin/KotlinExpressionTranspiler.kt +++ b/core/src/main/kotlin/eu/iamgio/pikt/expression/kotlin/KotlinExpressionTranspiler.kt @@ -20,7 +20,7 @@ class KotlinExpressionTranspiler(private val scope: Scope?) : ExpressionTranspil override fun string(expression: StringExpression) = "\"" + expression.components.joinToString("") { when (it) { is StringCharacter -> it.character.toString() - is StringReference -> "\${${sequence(it.sequence)}}" + is StringReference -> "\${${sequence(it.sequence)}()}" is StringBlankCharacter -> "" } } + "\""