diff --git a/kalk/src/parser.rs b/kalk/src/parser.rs index 3496910..cf126be 100644 --- a/kalk/src/parser.rs +++ b/kalk/src/parser.rs @@ -699,7 +699,11 @@ fn parse_identifier(context: &mut Context) -> Result { } } - split_into_variables(context, &identifier) + if identifier.pure_name.len() > 1 { + split_into_variables(context, &identifier) + } else { + Err(CalcError::UndefinedVar(identifier.full_name)) + } } }