about summary refs log tree commit diff
path: root/src/interpreter/mod.rs
diff options
context:
space:
mode:
authorGriffin Smith <root@gws.fyi>2021-03-14T15·53-0400
committerGriffin Smith <root@gws.fyi>2021-03-14T15·53-0400
commit39656a3801bb311edd9ebb65e92a24fc48f69ec7 (patch)
treed408937901c7789c033373019a94e014a03522a8 /src/interpreter/mod.rs
parent32a5c0ff0fc58aa6721c1e0ad41950bde2d66744 (diff)
Add string support to the frontend
Diffstat (limited to 'src/interpreter/mod.rs')
-rw-r--r--src/interpreter/mod.rs1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/interpreter/mod.rs b/src/interpreter/mod.rs
index 85a8928cbf..d414dedf85 100644
--- a/src/interpreter/mod.rs
+++ b/src/interpreter/mod.rs
@@ -29,6 +29,7 @@ impl<'a> Interpreter<'a> {
             Expr::Ident(id, _) => self.resolve(id),
             Expr::Literal(Literal::Int(i), _) => Ok((*i).into()),
             Expr::Literal(Literal::Bool(b), _) => Ok((*b).into()),
+            Expr::Literal(Literal::String(s), _) => Ok(s.clone().into()),
             Expr::UnaryOp { op, rhs, .. } => {
                 let rhs = self.eval(rhs)?;
                 match op {