Hi,

Matthew Bromberg, 27.12.2009 08:03:
> Alas no it's not just my installation, I have replicated the problem on 
> a clean install of windows 7 64 bit
>  on a new harddrive.  To install cython I used the technique of pointing 
> PYTHONPATH and path
>  to the cython0.12 directory.  I am running 32 bit version of 
> python2.6.4 and numpy.
 > [...]
> cmd.exe /c "C:\Program Files (x86)\Microsoft Visual Studio 
> 9.0\VC\vcvarsall.bat" x86&&  cl.exe /O2 /LD /EHsc /I. /IC:\python2
> sip\windows32\gpu_vsip.lib E:\Apps\CUDA\lib\cudart.lib 
> E:\Apps\CUDA\lib\cufft.lib&&  copy test.dll test.pyd
> Setting environment for using Microsoft Visual Studio 2008 x86 tools.
> Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 15.00.21022.08 
> for 80x86
> Copyright (C) Microsoft Corporation.  All rights reserved.
> 
> test.c
> test.c(812) : error C2143: syntax error : missing ';' before 'type'
> test.c(812) : error C2275: 'PyFrameObject' : illegal use of this type as 
> an expression
>         C:\python26\include\frameobject.h(47) : see declaration of 
> 'PyFrameObject'
> [...]
> Finally I show the relevant section of test.c
> 
> --------------- test.c -----------------------------
> 
> /* "E:\Projects\MUD\test.pyx":19
>  * cdef class rmat :
>  *
>  *     def __cinit__(self, int r, int c):             #<<<<<<<<<<<<<<
>  *         """ Generate a real matrix of r rows and c cols unitialized. """
>  *         cdef vsip_block_f *myb
>  */
> 
> static int __pyx_pf_4test_4rmat___cinit__(PyObject *__pyx_v_self, 
> PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
> static char __pyx_doc_4test_4rmat___cinit__[] = " Generate a real matrix 
> of r rows and c cols unitialized. ";
> static int __pyx_pf_4test_4rmat___cinit__(PyObject *__pyx_v_self, 
> PyObject *__pyx_args, PyObject *__pyx_kwds) {
>   int __pyx_v_r;
>   int __pyx_v_c;
>   int __pyx_r;
>   static PyObject **__pyx_pyargnames[] = {&__pyx_n_s__r,&__pyx_n_s__c,0};
>   __Pyx_RefNannySetupContext("__cinit__");
>   __Pyx_TraceCall("__cinit__", __pyx_f[0], 19); /* This is line 812 */
>   if (unlikely(__pyx_kwds)) {
> 
> 
> It looks like a bug to me.

Note that this is a totally different problem than what you originally 
reported. Cython seems to have run as expected now.

It might be possible that the macro definition of __Pyx_TraceCall() doesn't 
work smoothly with your compiler. Does the MS compiler have a way to output 
what the preprocessor made of the source? Like "gcc -E" does?

Stefan
_______________________________________________
Cython-dev mailing list
[email protected]
http://codespeak.net/mailman/listinfo/cython-dev

Reply via email to