Hi Earl,
> > Do I understand correctly that you want to use the object essentially like
> > a dictionary, just with obj.key instead of obj["key"]?
> > I consider this bad practice, since it isn't obvious to readers of your
> > code.
>
> Yes, you make a good point here, and it has made me question
> Do I understand correctly that you want to use the object essentially like
> a dictionary, just with obj.key instead of obj["key"]?
> I consider this bad practice, since it isn't obvious to readers of your
> code.
Yes, you make a good point here, and it has made me question the use
cases that I
Hi Earl,
> So I would wrap member functions returning the shared_ptr, and store a
> persistent reference to the python object, returning its shared_ptr
> instead?
Yes.
> > - Add all data attributes to the C++ object (and use .def_readonly() or
> > .def_readwrite()).
> > Then the state of the o
>> I've been bashing my head against a wall for the past couple of days
>
>> trying to figure this out. It's frustrating because it seems like it
>> should be such a simple thing.
>
> I cannot be so simple if you think of the C++ side as being unaware of
> the Python layer. Each time the C++ functi
Hi Erland,
> I've been bashing my head against a wall for the past couple of days
> trying to figure this out. It's frustrating because it seems like it
> should be such a simple thing.
I cannot be so simple if you think of the C++ side as being unaware of
the Python layer. Each time the C++ fun