[Pyrex] Parameter access error
Nicholas Riley
njriley at uiuc.edu
Tue Jan 9 14:55:16 UTC 2007
On Tue, Jan 09, 2007 at 06:51:52AM -0800, Natsagdorj Shagdar wrote:
> Hi list?
>
> In the following function code, pyrex gives an error "Expected an identifier or literal" on the line 2.
>
> cdef char *ReadFileIntoBuffer(char *FileName, unsigned long *fileSize):
> *fileSize = 0
>
> What is the correct way to access and change the value which the pointer fileSize points?
As stated in the documentation:
- There is no * operator in Pyrex. Instead of *p, use p[0]
so you should be able to use "fileSize[0] = 0".
--
Nicholas Riley <njriley at uiuc.edu> | <http://www.uiuc.edu/ph/www/njriley>
More information about the Pyrex
mailing list