LUMIERA.clone/wiki
Ichthyostega 68460d4900 Library: a subtle fix to iterator value-type deduction
After some investigation, I seem to understand the problem better now.
This builds upon the Introduction of our `ValueTraits´ two years ago:

e176e54004

The root cause to these ongoing sporadic problems with type deduction
seems to be that we encounter a **clash of concepts**: What Lumiera calls
an »Iterator« is essentially different to the order of terms used by the STL.
In the STL, an iterator can be seen as an ''abstracted pointer'', and is
thus only meaningful in conjunction with a backing container. It is also
this backing STL container that provides the value-type definitions.

In Lumiera however, an ''Iterator is a promise to retrieve a sequence of evaluations''.
For that reason, the Iterator itself provides value-type definitions,
and the notion of "iterable" can largely be conflated with "Lumiera Iterator".

Now, the `lib::RangeIter` can act as a bridge between both usage patterns,
and thus it is possible to create a `RangeIter` both from a Lumiera Iterator
or from a STL container. (As an aside, this is a similar idea as promoted
by the "Range TS" in C++20 -- yet the Lumiera iterator concept is much more
abstract and allows evaluations like tree expansion and search algorithms,
which would be never possible with the STL based notion of iteration)...

Thus the value type binding in `RangeIter` is the only correct place
where to mitigate this ''clash of concepts:''
 * if the `IT` parameter is a Lumiera iterator, we need to retrieve
   the type bindings defined therein
 * otherwise, we can assume that `IT` is an STL iterator and thus
   essentially a pointer, and we must strip that pointer and work from there.
2026-03-25 21:07:26 +01:00
..
draw Job-Planning: new draft - organise the overall planning process 2023-04-17 04:51:38 +02:00
DIR_INFO update some DIR_INFO entries 2011-04-05 00:44:30 +02:00
dump Scheduler-test: complete and document the Load-peak tests 2024-04-12 02:23:31 +02:00
empty.html TiddlyWiki: bugfix for Firefox Quantum -- use HTML5 web storage instead of a Cookie 2018-10-20 02:07:10 +02:00
InterfaceConcept_Varga.mm Lumiera GUI thoughts -- Mindmap to complement the Interface concept PDF 2015-04-26 23:22:42 +02:00
renderengine.html OutputSlot: complete connection of redesigned implementation (see #1415) 2026-03-23 00:31:12 +01:00
thinkPad.ichthyo.mm Library: a subtle fix to iterator value-type deduction 2026-03-25 21:07:26 +01:00
uml better use doc/devel/uml... 2007-06-21 02:57:49 +02:00
workflow.mm DOC: expand concept map 2014-10-25 01:56:44 +02:00
Workflow_Verwijlen.mm DOC: Notes regarding the ongoing workflow-discussion 2025-08-31 01:02:49 +02:00