C++ function called twice!!
Kristoffer Danielsson <[email protected]> Tue, 31 Jan 2012 23:12:12 +0100
| Newsgroups | gmane.comp.lang.lua.bind.user |
|---|---|
| Message-ID | <[email protected]> |
Luabind 0.9 (090216), Lua 5.1.3, VC++ 2010 SP1, debug mode. I have a complex script with a function. Let's call it "foo". I call "foo" using call_function<>. "foo" then calls C++ function "bar". You get the idea :P function foo(blah a) a:bar(x)end I have debugged this thoroughly and I'm convinced that "bar" is called twice. Putting debug printouts around it and catching breakpoints in my C++ code proves this. There is only one call to "bar" from Lua, yet it seems to call it twice. My parameters are pushed to the Lua stack ONCE. Has anyone of you guys encountered this weird behavior? Is it a known bug? My guess is that this is a bug inside LUA! Please advise! ------------------------------------------------------------------------------ Keep Your Developer Skills Current with LearnDevNow! The most comprehensive online learning library for Microsoft developers is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, Metro Style Apps, more. Free future releases when you subscribe now! http://p.sf.net/sfu/learndevnow-d2d _______________________________________________ luabind-user mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/luabind-user