libelektra
libelektra copied to clipboard
Remove internal iterators from C++ API
The internal iterator API (listed in #3171) will be removed from the C API. Corresponding functions need to removed from the C++ API and direct all uses within C++ code need to be replaced appropriately.
- [ ] Remove all functions (
rewind,next,setCursor, etc.) that map to the internal iterators API (keyRewind,keyNext, etc.) - [ ] Replace all usage of these functions and all direct uses of the C API for the internal iterators with alternatives
Note: Fully fixing this issue may require fixing #4279 as well. Some of the SWIG bindings refer to functions that will be removed with this issue.
Can be implemented as small project or big T3 work.
@markus2330 Please check whether the CM points need to adjusted, since this issue may partly be blocked by #4279.
Hello, @Milangs and I want to work on this issue for our CM-project. I think it's convenient that we additionally do #4279 and #4281 for the teamwork, because the three issues are related.
Remove internal iterators is an excellent job for project and teamwork. It is probably best to start replacing it in bindings (Ruby etc.), and then C++ iterator to use the external iterator instead; and finally remove the internal iterator from C (rewriting code with the external iterator instead).
Rationale for the change: When the client (i.e. the programmer) controls the iteration, the iterator is called external iterator. Otherwise, when the iterator controls the iteration, it is called internal iterator. Due to the fact that external iterators are more flexible the internal iterators will be removed completely from Elektra.
Everything finished except following issue: https://github.com/ElektraInitiative/libelektra/pull/4354#discussion_r884688010
@flo91 could this one more project? Or simply as normal issue?
@flo91 could this one more project? Or simply as normal issue?
For a project, the remaining work probably is a bit too small. I suggest to offer it as a big normal issue.
Additionally, I'd extend the scope to also remove the remaining internal iterations from the C-Code (see https://github.com/ElektraInitiative/libelektra/issues/3171)
I mark this stale as it did not have any activity for one year. I'll close it in two weeks if no further activity occurs. If you want it to be alive again, ping by writing a message here or create a new issue with the remainder of this issue. Thank you for your contributions :sparkling_heart:
I closed this now because it has been inactive for more than one year. If I closed it by mistake, please do not hesitate to reopen it or create a new issue with the remainder of this issue. Thank you for your contributions :sparkling_heart: