diff options
author | Stefan Behnel <stefan_ml@behnel.de> | 2014-08-17 15:20:11 +0200 |
---|---|---|
committer | Stefan Behnel <stefan_ml@behnel.de> | 2014-08-17 15:20:11 +0200 |
commit | 715b340a06ed73ba7e600a2f6669244017531b93 (patch) | |
tree | 3c140c8523656ae35b7ce209064e6c0fd8129c14 | |
parent | 159f48a995d425cc891c3ac50f99b47edf39e9de (diff) | |
download | cython-715b340a06ed73ba7e600a2f6669244017531b93.tar.gz |
exclude types from method call optimisation again (thinko: we're dealing with the actual types here, not with their attributes)
-rw-r--r-- | Cython/Compiler/Optimize.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/Cython/Compiler/Optimize.py b/Cython/Compiler/Optimize.py index be443ac13..14f10d131 100644 --- a/Cython/Compiler/Optimize.py +++ b/Cython/Compiler/Optimize.py @@ -3770,7 +3770,9 @@ class FinalOptimizePhase(Visitor.CythonTransform, Visitor.NodeRefCleanupMixin): node.arg_tuple.mult_factor or (node.arg_tuple.is_literal and node.arg_tuple.args)): # simple call, now exclude calls to objects that are definitely not methods may_be_a_method = True - if function.is_name: + if function.type is Builtin.type_type: + may_be_a_method = False + elif function.is_name: if function.entry.is_builtin: may_be_a_method = False elif function.cf_state: |