projects
/
cython.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
19cf712
)
set CYTHON_UNUSED modifier for __index__ special method
author
Lisandro Dalcin
<dalcinl@gmail.com>
Mon, 16 Aug 2010 18:53:31 +0000
(15:53 -0300)
committer
Lisandro Dalcin
<dalcinl@gmail.com>
Mon, 16 Aug 2010 18:53:31 +0000
(15:53 -0300)
Cython/Compiler/Nodes.py
patch
|
blob
|
history
diff --git
a/Cython/Compiler/Nodes.py
b/Cython/Compiler/Nodes.py
index 83bbec11fffdde3cd52940b088fbdea582a48c15..0d5312c027d17063533aca92bb0e0ee759a68673 100644
(file)
--- a/
Cython/Compiler/Nodes.py
+++ b/
Cython/Compiler/Nodes.py
@@
-1216,7
+1216,9
@@
class FuncDefNode(StatNode, BlockNode):
is_releasebuffer_slot = (self.entry.name == "__releasebuffer__" and
self.entry.scope.is_c_class_scope)
is_buffer_slot = is_getbuffer_slot or is_releasebuffer_slot
- if is_buffer_slot:
+ is_index_slot = (self.entry.name == "__index__" and
+ self.entry.scope.is_c_class_scope)
+ if is_buffer_slot or is_index_slot:
if 'cython_unused' not in self.modifiers:
self.modifiers = self.modifiers + ['cython_unused']