Difference between revisions of "TODO"

Jump to navigation Jump to search
1,181 bytes added ,  16:07, 23 November 2007
→‎General: Add TODO entries concerning our iterator implementation
(Remove obsolete Savegames TODO)
(→‎General: Add TODO entries concerning our iterator implementation)
Line 59: Line 59:
** backend specific stuff into ??? (maybe new namespace "Backends" ?)  not sure about this one.
** backend specific stuff into ??? (maybe new namespace "Backends" ?)  not sure about this one.
* Get rid of getenv in as many places as possible. Ideally, we'd only use it to query HOME on Unix systems.
* Get rid of getenv in as many places as possible. Ideally, we'd only use it to query HOME on Unix systems.
==== Iterator handling ====
* Our implementation of begin(/end) returning (const_)iterator is bugged, i.e. the current implementation for iterators of Common::List will not work with code like:
    Common::List<int> list;
    Common::List<int>::const_iterator x = list.begin();
It will fail with (i.e. gcc 4.2.3):
    error: conversion from ‘Common::List<int>::Iterator<int>’ to non-scalar type ‘Common::List<int>::Iterator<const int>’ requested
This is since our Common::List::Iterator implementation does not supply a copy constructor from Common::List::Iterator<int> to the specific type. Check for example Common::HashMap::Iterator for a (rather hacky) implementation of it, or [http://gcc.gnu.org/onlinedocs/libstdc++/latest-doxygen/stl__tree_8h-source.html#l00221 the GNU libstdc++ implementation] (example for std::map iterators).
* Implement proper reverse_iterators for Common::List. Our current implementation is the same as forward iterators, just that rbegin will return the last element instead of the first and there is no rend. Check [http://www.sgi.com/tech/stl/ReverseIterator.html SGI Documentation] for proper description of revese_iterator in the STL.


==== Event recorder ====
==== Event recorder ====
561

edits

Navigation menu