In python, I make a call to a calculate function inn my pyx file, which then calls other cdef functions.
python function:
def getCoord():
array = ['A','B','C','D']
px = 5
py = 6
move = pyxFile.calculateCoord( array, x, y )
pyx function:
def calculateCoord( array, px, py):
cdef vector[ char ] b
for i in range( len( array) ):
b.push_back( array[ i ] )
return search( b, px, py )
I'm trying to pass a python array of characters to a vector[char] for use in my cdef functions, but my error is an integer is required on the line b.push_back( array[ i ] )
x and y are integers
search (a cdef function) returns a tuple of integers