lumiera_/wiki
Ichthyostega 4e26d655a8 Library: workaround for tricky problems with Template-Argument-Deduction
We use a DataSrc<DAT> template to access the actual data to be substituted.
However, when applying the Text-Template, we need to pick the right
specialisation, based on the type of the actual data provided.

Here we face several challenges:

 * Class-Template-Argument-Deduction starts from the *primary* template's constructors.
   Without that, the compiler will only try the copy constructor and will
   never see the constructors of partial specialisations.
   This can be fixed by providing a ''dummy constructor''.
 * The specifics of how to provide a custom CTAD deduction guide
   for a **nested template** are not well documented. I have found
   several bug reports, and seemingly one of these bugs failed my
   my various attempts. Moreover it is ''not clear if such a deduction
   guide can even be given outside of the class definition scope.''
   For the intended usage pattern this would be crucial, since users
   are expected to provide further specialisations of the DataSrc-template
 * Thus I resorted to the ''old school solution,'' which is to use
   a ''free builder function'' as an extension point. Thus users could
   provide further overloads for the `buildDataSrc()` function.
 * Unfortunately, SFINAE-Tricks are way more limited for function overload.
   Thus it seems impossible to have a generic and more specialised cases,
   unless all special cases are disjoint.

Thus the solution is far from perfect, ''yet for the current situation it seems
sufficient'' (and C++20 Concepts will greatly help to resolve this kind of problems)
2024-03-26 02:41:42 +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
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 Scheduler-test: draft a structure to formalise these investigations 2024-01-03 00:45:17 +01:00
thinkPad.ichthyo.mm Library: workaround for tricky problems with Template-Argument-Deduction 2024-03-26 02:41:42 +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