James Kanze
10/30/2008 9:45:00 AM
On Oct 29, 4:02 pm, Lionel B <m...@privacy.net> wrote:
> On Wed, 29 Oct 2008 07:05:24 -0700, Krice wrote:
> > On 29 loka, 15:50, Lionel B <m...@privacy.net> wrote:
> Yup :-) In future I shall read posts first before responding.
> Might I suggest, though, that `o' is a pretty bad choice of
> name for an identifier (though I have been known to use it
> myself, along with `l').
Not as bad as O (capital):-). (I once saw a program which used
only O, l, 0, 1 and _ in symbols. The source code looked like a
binary dump. And it was a candidate for IOCCC, not production
code.)
If it makes you feel better, I misread it like you did the first
time as well.
> Apart from that I don't see a problem in the code you post,
> which suggests a bug in some other part of your code. A
> compileable example demonstrating the problem would certainly
> help.
Except that in his line:
item_list.erase(pos);
pos isn't an iterator into item_list.
It's true that if he had tried to make his example compilable,
he probably would have found the problem immediately, because he
only would have declared one list, and the compiler would have
complained "symbol not defined" for the other.
--
James Kanze (GABI Software) email:james.kanze@gmail.com
Conseils en informatique orientée objet/
Beratung in objektorientierter Datenverarbeitung
9 place Sémard, 78210 St.-Cyr-l'École, France, +33 (0)1 30 23 00 34