Mercurial > hg > vampy
diff PyTypeInterface.cpp @ 46:af9c4cee95a8
VC++ fixes.
Much of this is changing "and" to "&&". I had never realised
until today that "and" is in fact a keyword in C++, albeit not
one that has been there since the start, so this should compile
(I eventually looked this up having been puzzled by how this
code could ever build with any other compiler). However,
despite its keywordness, "and" still doesn't seem to be acceptable
to VC++. Possibly there's an option to change this, or one could
use a macro -- but why not just stick with the token that compilers
are known to like?
author | cannam |
---|---|
date | Mon, 05 Oct 2009 16:14:25 +0000 |
parents | 94d09b4027aa |
children | c1e4f706ca9a |
line wrap: on
line diff
--- a/PyTypeInterface.cpp Mon Oct 05 13:57:10 2009 +0000 +++ b/PyTypeInterface.cpp Mon Oct 05 16:14:25 2009 +0000 @@ -311,7 +311,7 @@ } // convert the first element of iterable sequences - if (PySequence_Check(pyValue) and PySequence_Size(pyValue) > 0) + if (PySequence_Check(pyValue) && PySequence_Size(pyValue) > 0) { PyObject* item = PySequence_GetItem(pyValue,0); if (item)