translator: fix block in when expression
This commit is contained in:
@@ -84,6 +84,10 @@ abstract class BlockCodegen(val state: TranslationState, val variableManager: Va
|
|||||||
|
|
||||||
fun evaluateExpression(expr: PsiElement?, scopeDepth: Int): LLVMSingleValue? {
|
fun evaluateExpression(expr: PsiElement?, scopeDepth: Int): LLVMSingleValue? {
|
||||||
return when (expr) {
|
return when (expr) {
|
||||||
|
is KtBlockExpression -> {
|
||||||
|
expressionWalker(expr.firstChild, scopeDepth + 1)
|
||||||
|
return null
|
||||||
|
}
|
||||||
is KtBinaryExpression -> evaluateBinaryExpression(expr, scopeDepth)
|
is KtBinaryExpression -> evaluateBinaryExpression(expr, scopeDepth)
|
||||||
is KtPostfixExpression -> evaluatePostfixExpression(expr, scopeDepth)
|
is KtPostfixExpression -> evaluatePostfixExpression(expr, scopeDepth)
|
||||||
is KtPrefixExpression -> evaluatePrefixExpression(expr, scopeDepth)
|
is KtPrefixExpression -> evaluatePrefixExpression(expr, scopeDepth)
|
||||||
|
|||||||
Reference in New Issue
Block a user