Untitled

Published September 25, 2006
Advertisement


Python -> "calls" C -> "calls" Python -> Propagates expected value!

Yayayayay. Now to flesh out the templates so they accept more than 2 argument functions (lolol lots of repetitive template code to write :O) and then to do the data sharing between Python<->C. Basically, registering C structs as Python object types.

Also, I think I've found a way to get around the dilemma discussed before (the call('funcname') syntax with Pythong) - functions can be represented in Python as an object which implements __call__ (essentially a function object). If I (from C++) create such an object whose __call__ method passes the arguments AND a unique string to identify which function is being called to the function call handler in C++, then I can effectively use the desired (normal) syntax funcname(args). Which is cool.

It'll take a couple more days to implement that though :(
Previous Entry Untitled
Next Entry Untitled
0 likes 2 comments

Comments

Mushu
y thank yuo.

I'll try to spice it up later in the week with some sauce. How does that sound?
September 25, 2006 10:52 PM
You must log in to join the conversation.
Don't have a GameDev.net account? Sign up!
Profile
Author
Advertisement

Latest Entries

Untitled

5590 views

Untitled

1081 views

Untitled

1225 views

Untitled

1136 views

Untitled

1183 views

Untitled

1467 views

Untitled

1135 views

Untitled

1036 views

Untitled

1040 views

Untitled

1220 views
Advertisement