aboutsummaryrefslogtreecommitdiffstats
path: root/modelica-parser-lalrpop/src/ast.rs
diff options
context:
space:
mode:
authorbnewbold <bnewbold@robocracy.org>2017-01-14 19:41:51 -0800
committerbnewbold <bnewbold@robocracy.org>2017-01-14 19:52:56 -0800
commit11569fdec123e9c7aeaf38d8a122842c4c758fdf (patch)
tree2940f78906772581812211e00f93228a63ac30de /modelica-parser-lalrpop/src/ast.rs
parentf8b7d9d7e936bb53db3f978b54592b7af791d1ec (diff)
downloadmodelthing-11569fdec123e9c7aeaf38d8a122842c4c758fdf.tar.gz
modelthing-11569fdec123e9c7aeaf38d8a122842c4c758fdf.zip
parse out exponentiation
Diffstat (limited to 'modelica-parser-lalrpop/src/ast.rs')
-rw-r--r--modelica-parser-lalrpop/src/ast.rs3
1 files changed, 3 insertions, 0 deletions
diff --git a/modelica-parser-lalrpop/src/ast.rs b/modelica-parser-lalrpop/src/ast.rs
index f1e7d93..317944b 100644
--- a/modelica-parser-lalrpop/src/ast.rs
+++ b/modelica-parser-lalrpop/src/ast.rs
@@ -103,6 +103,7 @@ pub enum MathUnaryFunc {
pub enum BinOperator {
Multiply,
Divide,
+ Exponentiate,
Add,
Subtract,
}
@@ -313,6 +314,8 @@ impl Debug for BinOperator {
match *self {
Multiply => write!(fmt, "*"),
Divide => write!(fmt, "/"),
+ // TODO: this doesn't really work here
+ Exponentiate => write!(fmt, "^"),
Add => write!(fmt, "+"),
Subtract => write!(fmt, "-"),
}