Pickle for C++?

Warren Postma embed at NOSPAM.geocities.com
Wed Jun 28 13:23:34 EDT 2000


"Courageous" <jkraska1 at san.rr.com> wrote in message
news:395A3049.2E783D21 at san.rr.com...
>
> > > Is there any solution out there or have I to write my own C++ - pickle
> > > algorithm?
> >
> > Embed Python into your C++ application, and don't bother trying to tie a
> > static language to a dynamic one by making a set of fixed C strucutres.
> > Believe me it's a waste of time.
> >
> > You can embed the Python DLL or shared library into your C++ application
in
> > a matter of minutes, and then unpacking your data will be a single line
call
> > to a Python function that will unpack your structure and a simple set of
> > functions to get and set the data in your python objects.
>
> This is good advice, but I think the question remains outstanding
> for those individuals in situations where, for whatever reason, doing
> what you recommend really isn't appropriate.
>

Suppose I implement Module X that can unpickle anything that Python can
pickle.  I believe it is reasonable to assert that Module X must therefore
be either (a) Python, (b) a fairly Large Subset or Reinvention of Python.

I suggest that in any case where Python is not appropriate, Pickle may also
not be appropriate.

XML-RPC/SOAP might become an intriguing possibility for those situations.

Warren





More information about the Python-list mailing list