Changes between Version 33 and Version 34 of DeveloperGuidelines/Py_2_3
- Timestamp:
- 07/02/19 12:04:21 (6 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
DeveloperGuidelines/Py_2_3
v33 v34 133 133 The same applies to {{{dict.iterkeys()}}} (use {{{dict.keys()}}} instead) and {{{dict.itervalues()}}} (use {{{dict.values()}}} instead). 134 134 135 === No dict.has_key === 136 137 The {{{dict.has_key()}}} method has been removed in Python-3 in favor of the {{{x in y}}} pattern, which is also available (and equivalent) in Python-2.7: 138 139 {{{#!python 140 # Deprecated: 141 if d.has_key(k): 142 # New Standard: 143 if k in d: 144 }}} 135 145 === Map and Zip return generators === 136 146