cache Expr::getStringValue

This commit is contained in:
Erik Krogh Kristensen
2020-05-19 12:12:23 +02:00
parent f952293ba0
commit dbc25ca3fb

View File

@@ -108,7 +108,7 @@ class Expr extends @expr, ExprOrStmt, ExprOrType, AST::ValueNode {
int getIntValue() { none() }
/** Gets the constant string value this expression evaluates to, if any. */
string getStringValue() { none() }
cached string getStringValue() { none() }
/** Holds if this expression is impure, that is, its evaluation could have side effects. */
predicate isImpure() { any() }