Add no_custom_syntax.

This commit is contained in:
Stephen Chung
2022-07-05 22:59:03 +08:00
parent b6528bd51d
commit b4dbc7619a
18 changed files with 121 additions and 43 deletions

View File

@@ -1231,6 +1231,7 @@ fn optimize_expr(expr: &mut Expr, state: &mut OptimizerState, _chaining: bool) {
}
// Custom syntax
#[cfg(not(feature = "no_custom_syntax"))]
Expr::Custom(x, ..) => {
if x.scope_may_be_changed {
state.propagate_constants = false;