[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: tolua++ code generation issues
- From: Sam Roberts <sroberts@...>
- Date: Fri, 6 Oct 2006 11:35:34 -0700
On Fri, Oct 06, 2006 at 02:21:24PM -0300, Frederico Ferro Schuh wrote:
> void doStuff(const std::string& p1, int p2, const std::string& p3,
> const char* p4);
> };
> // the actual method call
> self->doStuff(p1,p2,p3,p4);
> tolua_pushcppstring(tolua_S,(const char*)p1);
> tolua_pushcppstring(tolua_S,(const char*)p3);
I know nothing about tolua, but I would guess that since the std:string
arguments are called as references, they may actually be output
arguments, so they are pushed back to lua after the call.
Except that the reference arguments are const... so can't be return
values, so perhaps its a bug that the "const" isn't respected?
Cheers,
Sam