Skip to content

Prefer ADL customization over functions in Sel::Utils namespace

The following discussion from !2568 (merged) should be addressed:

  • @graven started a discussion:

    reminder to self (i.e. turn into an issue): we should change this so that this line can be:

          auto const decay_vertex_position = endVertexPos( composite );

    i.e. any 'composite' should define, in its own namespace, a endVertexPos function -- so that it can be found using ADL. That way we can avoid introducing a 'central' place (in Sel::Utils) which must know about every possible supported type -- and it allows to keep endVertexPos next to the actual code it interacts with instead, i.e. it is a more scalable solution (and one of the reasons ADL and namespaces were introducing into the language in the first place, so why not make use of them...).