[invalid]Linked list should return a reference.

You discovered a bug in the engine, and you are sure that it is not a problem of your code? Just post it in here. Please read the bug posting guidelines first.
Post Reply
BlindSide
Admin
Posts: 2821
Joined: Thu Dec 08, 2005 9:09 am
Location: NZ!

[invalid]Linked list should return a reference.

Post by BlindSide »

When you de-reference an irrList iterator, it returns a copy, not a reference. It would make life much easier me-thinks if it were to returns a reference of the object so we can modify it, grab it's address, etc. Is there any particular reason/design decision why it does not at the moment?
Last edited by BlindSide on Sat Nov 22, 2008 3:54 am, edited 1 time in total.
ShadowMapping for Irrlicht!: Get it here
Need help? Come on the IRC!: #irrlicht on irc://irc.freenode.net
vitek
Bug Slayer
Posts: 3919
Joined: Mon Jan 16, 2006 10:52 am
Location: Corvallis, OR

Post by vitek »

I think you are mistaken. Have a look at the declaration in irrList.h. As you can see, the iterators returns references from the operator* and pointers from operator->. Perhaps you could show use the code that is giving you trouble?

Travis
BlindSide
Admin
Posts: 2821
Joined: Thu Dec 08, 2005 9:09 am
Location: NZ!

Post by BlindSide »

You're right, I need to get my eyes checked.
ShadowMapping for Irrlicht!: Get it here
Need help? Come on the IRC!: #irrlicht on irc://irc.freenode.net
Post Reply