From 4eb1ce4371038f36ff7d4c57a5193a64fbc2f75f Mon Sep 17 00:00:00 2001 From: Andreas Kloeckner <kloeckner@haamster.(none)> Date: Mon, 1 Dec 2008 17:47:27 -0600 Subject: [PATCH] Fix bug in StringifyMapper. --- src/mapper/stringifier.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/mapper/stringifier.py b/src/mapper/stringifier.py index 0ae98c4..36d30cb 100644 --- a/src/mapper/stringifier.py +++ b/src/mapper/stringifier.py @@ -99,8 +99,8 @@ class StringifyMapper(pymbolic.mapper.RecursiveMapper): def map_power(self, expr, enclosing_prec): return self.parenthesize_if_needed( self.format("%s**%s", - self.rec(expr.numerator, PREC_POWER), - self.rec(expr.denominator, PREC_POWER)), + self.rec(expr.base, PREC_POWER), + self.rec(expr.exponent, PREC_POWER)), enclosing_prec, PREC_POWER) def map_polynomial(self, expr, enclosing_prec): -- GitLab