Re: [Interest] .remove() feature?

2016-09-23 Thread Thiago Macieira
On sexta-feira, 23 de setembro de 2016 05:59:28 PDT Roland Hughes wrote: > Currently working at a site which is using 5.4 commercial under Ubuntu > 14.04 to develop an embedded system. Spent days tracking down a bug in > the current project code base. There was an ugly for() loop which was >

Re: [Interest] .remove() feature?

2016-09-23 Thread Roland Hughes
Lorenz, Good call. I went back through the code. Was actually a QList<> not a QHash, but . . . your mention of shared was the light which shined on the monster. The pointer held in the QList was a pointer to an object declared with CANBUSSHARED_EXPORT. Thank you very much! I hate mystery

Re: [Interest] .remove() feature?

2016-09-23 Thread Lorenz Haas
> It was a C++ for (int x=0;...) loop, but we are compiling for C++ 11 Hm, then my guess would be that they were working on a QHash/container that was shared and the first remove() performed a detach. Thus the loop worked on a copy. Best Lorenz ___

Re: [Interest] .remove() feature?

2016-09-23 Thread Roland Hughes
It was a C++ for (int x=0;...) loop, but we are compiling for C++ 11 On 09/23/2016 07:44 AM, Lorenz Haas wrote: Hi, Has anybody else seen this behavior in 5.x? Is removeAt() really queueing a low priority event so the removeAt() doesn't actually happen until the event queue is processed

Re: [Interest] .remove() feature?

2016-09-23 Thread Lorenz Haas
Hi, > Has anybody > else seen this behavior in 5.x? Is removeAt() really queueing a low priority > event so the removeAt() doesn't actually happen until the event queue is > processed completely? my QHash only has a remove() function. Also, it removes the item right away, no events involved:

[Interest] .remove() feature?

2016-09-23 Thread Roland Hughes
Currently working at a site which is using 5.4 commercial under Ubuntu 14.04 to develop an embedded system. Spent days tracking down a bug in the current project code base. There was an ugly for() loop which was processing a QHash (which really should have been a queue). They were calling