On Jan 30, 1:58 pm, Gabriel Genellina <[EMAIL PROTECTED]> wrote:
> On 30 ene, 01:58, grbgooglefan <[EMAIL PROTECTED]> wrote:
>
> > How do I pass the elements populated in struct variables of this
> > vector dynamically to PyEval_CallFunction, in the fashion somewhat
> > like below?
> > PyEval_CallFunction(obj, "iii", 
> > vector[0].ioparam->nionum,vector[1].ioparam->nionum,vector[2].ioparam->nion­um);
>
> > PyEval_CallFunction(obj, "di", 
> > vector[0].ioparam->fionum,vector[1].ioparam->nionum);
>
> > PyEval_CallFunction(obj, "diiisis", 
> > vector[0].ioparam->fionum,vector[1].ioparam->nionum,vector[2].ioparam-
> > >nionum,vector[3].ioparam->nionum,vector[4].ioparam-
> > >ioString,vector[5].ioparam->nionum,vector[6].ioparam->ioString);
>
> I didn't know of PyEval_CallFunction until now, but aparently the
> lines above are OK. Can't you use it that way? What's your problem?
>
> --
> Gabriel Genellina

slowness of current code - vector is to parsed one by one & switch
adds another time for checks.
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to