Re: [C++-sig] wrapped std::vector slice affecting items in a python list

2012-04-02 Thread babak
rough it change, instead of becoming detached. babak -- View this message in context: http://boost.2283326.n4.nabble.com/wrapped-std-vector-slice-affecting-items-in-a-python-list-tp3738972p4527267.html Sent from the Python - c++-sig mailing list archive at Nabbl

Re: [C++-sig] Iterating over small objects

2012-01-23 Thread Babak Khataee
iteration. On 19 January 2012 19:37, Jim Bosch wrote: > On 01/19/2012 02:08 PM, babak wrote: > >> Hi guys, >> >> Has anyone encountered (what feels like) quite slow iteration when looping >> over small containers ? I'm in a situation where I'm iterating over

[C++-sig] Iterating over small objects

2012-01-19 Thread babak
a guess. Alternatively my perspective on what the iteration speed should be might be completely skewed, so any help in clarifying what's going on here would be greatly appreciated. thanks Babak http://boost.2283326.n4.nabble.com/file/n4311109/source.cpp source.cpp http://boost.2283326.n4.na

Re: [C++-sig] wrapped std::vector slice affecting items in a python list

2011-08-17 Thread Babak Khataee
okay cool. I think that's a reasonable compromise. It should also (hopefully) make it possible to move away from the indexing suite as well. thanks for your help! On 16 August 2011 21:41, Jim Bosch wrote: > On 08/16/2011 11:29 AM, Babak Khataee wrote: > >> Okay th

Re: [C++-sig] wrapped std::vector slice affecting items in a python list

2011-08-16 Thread Babak Khataee
Okay thanks for the info. Things are also a lot safer if you only wrap vectors as const; it's exposing > the mutators to Python that gets really difficult. > Is the const-ness of a wrapped object just a side effect of not exposing methods which modify it or is it due to something else more explic

Re: [C++-sig] wrapped std::vector slice affecting items in a python list

2011-08-16 Thread babak
Hi Jim Thanks for your response. I'm abit surprised that this is the case, I kind of thought that indexing_suite was there to bridge this incompatibility. Is it normal then for large projects reliant on value based containers to copy data when going from python to c++ ? thanks babak --

[C++-sig] wrapped std::vector slice affecting items in a python list

2011-08-12 Thread babak
ms in the python list change. The attached example illustrates this. Is this behaviour expected ? I'm quite confused as to what's going on so any help clarifying this would be greatly appreciated. thanks, Babak http://boost.2283326.n4.nabble.com/file/n3738972/test.py test.py http://b