Kotlin Analysis API Documentation Help

KaCompoundOperation

KaCompoundOperation describes the kind of compound update applied in a +=/-=/*=//=/%= assignment or a ++/-- increment/decrement. It is exposed by both KaCompoundVariableAccessCall and KaCompoundArrayAccessCall through their compoundOperation field.

Hierarchy

KaCompoundOperation

KaCompoundAssignOperation

KaCompoundUnaryOperation

Members

val operationCall: KaFunctionCall<KaNamedFunctionSymbol>

The call of the function that computes the value for this compound access — the plus for +=, the inc for ++, and so on. This is also exposed directly on KaCompoundAccessCall.operationCall for convenience.

The legacy operationPartiallyAppliedSymbol accessor is @Deprecated. Use operationCall instead.

KaCompoundAssignOperation

Represents a compound assignment that reads, computes, and writes back. Note that direct calls to <op>Assign operator functions (like MutableList.plusAssign) are not represented as a compound operation — they are simple KaFunctionCalls.

val kind: Kind

One of PLUS_ASSIGN, MINUS_ASSIGN, TIMES_ASSIGN, DIV_ASSIGN, REM_ASSIGN.

val operand: KtExpression

The right-hand-side operand. The left-hand side lives in the parent KaVariableAccessCall/KaCompoundArrayAccessCall.

KaCompoundUnaryOperation

Represents a compound unary access++ or -- — that reads, increments/decrements, and writes back.

val kind: Kind

INC or DEC.

val precedence: Precedence

Whether the operator is PREFIX (++a) or POSTFIX (a++).

19 May 2026