aboutsummaryrefslogtreecommitdiffstats
path: root/src/compiler.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/compiler.rs')
-rw-r--r--src/compiler.rs7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/compiler.rs b/src/compiler.rs
index 409d6a6..70c9a51 100644
--- a/src/compiler.rs
+++ b/src/compiler.rs
@@ -87,6 +87,13 @@ impl From<&Value> for Type {
}
impl Type {
+ pub fn is_unkown(&self) -> bool {
+ match self {
+ Type::UnknownType => true,
+ _ => false,
+ }
+ }
+
pub fn as_value(&self) -> Value {
match self {
Type::Void => Value::Nil,