467,161 Members | 873 Online
Bytes | Developer Community
Ask Question

Home New Posts Topics Members FAQ

Post your question to a community of 467,161 developers. It's quick & easy.

How to extract python dict from c++?

i have a python function like this :
def func1(**fields) :
...


fields is a python dict, in python i can send the following to the function :

c = dict(a="3",b="4",f="3")
func1(**c)

assuming i want to call the func1 from c++ , and i create the dict from the following functions :

PyObject* PyDict_New();
then :
PyDict_SetItem
PyDict_SetItem
...

how to call the func1 ?
or in other words how to add the **(double star) from c code ?
Jan 8 '11 #1
  • viewed: 1020
Share:

Post your reply

Sign in to post your reply or Sign up for a free account.

Similar topics

1 post views Thread by venu gopal | last post: by
8 posts views Thread by rbt | last post: by
10 posts views Thread by Elric02@rogers.com | last post: by
10 posts views Thread by could.net@gmail.com | last post: by
3 posts views Thread by dmitrey | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.