[SciPy-dev] patch: allow arrayobject.h to compile in c++ compiler

Fernando Perez Fernando.Perez at colorado.edu
Tue Nov 22 02:27:53 EST 2005


Andrew Straw wrote:
> Bool is defined in C++ compilers, so if arrayobject.h defines Bool, the
> compiler issues an error: "redeclaration of C++ built-in type `int'".
> 
> And, in an apparent shortcoming of Trac, I can't seem to submit a
> patch.  Is that really so?

well, at least the trac instance ipython uses (which should be the same 
running in scipy) does have an 'Attach file' button in all ticket pages.  You 
should be able to attach patches via that button.  It is true that it doesn't 
seem to have a _specific_ patch tracker though, only generic attachments.

> Here's a patch which allows C++ source to be compiled against
> scipy/arrayobject.h:

In any case, I just applied your patch.  I didn't test a C++ build, but I 
failt to see how that 2-line #ifdef could possibly cause any harm, so I went 
ahead with the commit.  Hopefully I didn't screw up (last time I committed a 
patch without careful testing Pearu had to clean up my mess :)

Cheers,

f




More information about the SciPy-Dev mailing list