-z, --pre-import <module> If specified, assume undeclared names in this
module. Emulates the behavior of putting
"from <module> import *" at the top of the file.
- --incref-local-binop Force local an extra incref on local variables before
- performing any binary operations.
--cleanup <level> Release interned objects on python exit, for memory debugging.
Level indicates aggressiveness, default 0 releases nothing.
-w, --working <directory> Sets the working directory for Cython (the directory modules
Options.embed_pos_in_docstring = 1
elif option in ("-z", "--pre-import"):
Options.pre_import = pop_arg()
- elif option == "--incref-local-binop":
- Options.incref_local_binop = 1
elif option == "--cleanup":
Options.generate_cleanup_code = int(pop_arg())
elif option in ("-D", "--no-docstrings"):
self.coerce_operands_to_pyobjects(env)
self.type = py_object_type
self.is_temp = 1
- if Options.incref_local_binop and self.operand1.type.is_pyobject:
- self.operand1 = self.operand1.coerce_to_temp(env)
else:
self.analyse_c_operation(env)
self.dup = self.create_dup_node(env) # re-assigns lhs to a shallow copy
self.rhs.analyse_types(env)
self.lhs.analyse_target_types(env)
- if Options.incref_local_binop and self.dup.type.is_pyobject:
- self.dup = self.dup.coerce_to_temp(env)
import ExprNodes
if self.lhs.type.is_pyobject:
self.rhs = self.rhs.coerce_to_pyobject(env)
pre_import = None
docstrings = True
-# This is a SAGE-specific option that will
-# cause Cython to incref local variables before
-# performing a binary operation on them, for
-# safe detection of inplace operators.
-incref_local_binop = 0
-
# Decref global variables in this module on exit for garbage collection.
# 0: None, 1+: interned objects, 2+: cdef globals, 3+: types objects
# Mostly for reducing noise for Valgrind, only executes at process exit