From 86e8e7c558b296018613ed979012b2aca493ffbb Mon Sep 17 00:00:00 2001 From: Mike Bayer Date: Mon, 13 Dec 2010 00:15:32 -0500 Subject: - why type.dialect_impl(dialect).bind_processor(dialect), caching just the impl? just call type._cached_bind_processor(dialect), cache the impl *and* the processor function. same for result sets. - use plain dict + update for defaultexecutioncontext.execution_options --- lib/sqlalchemy/sql/compiler.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib/sqlalchemy/sql/compiler.py') diff --git a/lib/sqlalchemy/sql/compiler.py b/lib/sqlalchemy/sql/compiler.py index d5b877a35..0c76f3e74 100644 --- a/lib/sqlalchemy/sql/compiler.py +++ b/lib/sqlalchemy/sql/compiler.py @@ -262,7 +262,7 @@ class SQLCompiler(engine.Compiled): self._memos[key] = processors = dict( (key, value) for key, value in ( (self.bind_names[bindparam], - bindparam.bind_processor(dialect)) + bindparam.type._cached_bind_processor(dialect)) for bindparam in self.bind_names ) if value is not None ) @@ -596,7 +596,7 @@ class SQLCompiler(engine.Compiled): def render_literal_bindparam(self, bindparam, **kw): value = bindparam.value - processor = bindparam.bind_processor(self.dialect) + processor = bindparam.type._cached_bind_processor(self.dialect) if processor: value = processor(value) return self.render_literal_value(value, bindparam.type) -- cgit v1.2.1