[FIX] mutable default in tools
lp bug: https://launchpad.net/bugs/525808 fixed bzr revid: ls@numerigraphe.fr-20100722135436-grgj7vow495q65vf
This commit is contained in:
parent
70fd90d33b
commit
666c4ec067
|
@ -598,7 +598,7 @@ form: module.record_id""" % (xml_id,)
|
|||
self.pool.get('ir.model.data').ir_set(cr, self.uid, 'action', 'tree_but_open', 'Menuitem', [('ir.ui.menu', int(pid))], action, True, True, xml_id=rec_id)
|
||||
return ('ir.ui.menu', pid)
|
||||
|
||||
def _assert_equals(self, f1, f2, prec = 4):
|
||||
def _assert_equals(self, f1, f2, prec=4):
|
||||
return not round(f1 - f2, prec)
|
||||
|
||||
def _tag_assert(self, cr, rec, data_node=None):
|
||||
|
|
|
@ -164,7 +164,7 @@ d[types.InstanceType] = _copy_inst
|
|||
|
||||
del d
|
||||
|
||||
def deepcopy(x, memo=None, _nil=[]):
|
||||
def deepcopy(x, memo=None, _nil=None):
|
||||
"""Deep copy operation on arbitrary Python objects.
|
||||
|
||||
See the module's __doc__ string for more info.
|
||||
|
@ -172,6 +172,8 @@ def deepcopy(x, memo=None, _nil=[]):
|
|||
|
||||
if memo is None:
|
||||
memo = {}
|
||||
if _nil is None:
|
||||
_nil = {}
|
||||
|
||||
d = id(x)
|
||||
y = memo.get(d, _nil)
|
||||
|
|
|
@ -58,7 +58,7 @@ trailer
|
|||
%%EOF
|
||||
"""
|
||||
|
||||
def output_field( f ):
|
||||
def output_field(f):
|
||||
return "\xfe\xff" + "".join( [ "\x00"+c for c in f ] )
|
||||
|
||||
def extract_keys(lines):
|
||||
|
|
Loading…
Reference in New Issue