diff --git a/dust-lang/src/context.rs b/dust-lang/src/context.rs index 38aa9ab..d967e77 100644 --- a/dust-lang/src/context.rs +++ b/dust-lang/src/context.rs @@ -50,10 +50,10 @@ impl<'a> Context<'a> { } pub fn get_type(&self, identifier: &Identifier) -> Result, ValidationError> { - if let Some((value_data, _)) = self.variables.read()?.get(identifier) { + if let Some((data, _)) = self.variables.read()?.get(identifier) { log::trace!("Getting {identifier}'s type."); - let r#type = match value_data { + let r#type = match data { VariableData::Type(r#type) => r#type.clone(), VariableData::Value(value) => value.r#type(self)?, };