parseExpressionWith

fun parseExpressionWith(expression: String, vararg declaredVars: String): KthParsingResult

Parses an arithmetic expression from the given string and declared variables using the default context.

Any unknown alphanumeric token that is not a number, an element or a declared variable is considered illegal.

Return

the parsed KthExpression

Parameters

expression

the arithmetic expression to parse

declaredVars

the declared vars that can be used in the expression

See also


@JvmName(name = "parseExpressionWithExt")
fun String.parseExpressionWith(vararg declaredVars: String): KthParsingResult

Parses an arithmetic expression from the receiving string and declared variables using the default context.

Any unknown alphanumeric token that is not a number, an element or a declared variable is considered illegal.

Return

the parsed KthExpression

Parameters

declaredVars

the declared vars that can be used in the expression

See also