From 4ffb47d45fcfa7c2e7bbfcab19aced632800b6e4 Mon Sep 17 00:00:00 2001 From: Andreas Kloeckner <inform@tiker.net> Date: Mon, 2 Apr 2012 20:16:44 -0400 Subject: [PATCH] Fix (remove) CSE mapper caching. --- pymbolic/cse.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pymbolic/cse.py b/pymbolic/cse.py index 120af26..bb71581 100644 --- a/pymbolic/cse.py +++ b/pymbolic/cse.py @@ -70,7 +70,7 @@ class UseCountMapper(WalkMapper): -class CSEMapper(IdentityMapper, CSECachingMapperMixin): +class CSEMapper(IdentityMapper): def __init__(self, to_eliminate, get_key): self.to_eliminate = to_eliminate self.get_key = get_key @@ -104,7 +104,7 @@ class CSEMapper(IdentityMapper, CSECachingMapperMixin): map_floor_div = map_sum map_call = map_sum - def map_common_subexpression_uncached(self, expr): + def map_common_subexpression(self, expr): # Avoid creating CSE(CSE(...)) # # NOTE: This is not equivalent to isinstance--it's more specific, -- GitLab