A question about Hana:
Say I want to incrementally collect data in a tuple (or an equivalent heterogeneous container), i.e. incrementally add another value (and type) to the tuple.
I could use std::tuple_cat but I would need to copy and store the result in a different local variable for each such cat.
I can’t use std::any since I won’t know the contained type. Is there such a way to extract the contained type of an any?
Is it possible to have a single local variable that supports such "insert"s preferably without copying?
Does Hana have such a facility?
One obvious way to do this is to incrementally serialize the data (e.g. to json) and reparse it later, but this seems a bit roundabout.
//...operations into separate functions. IMO large multipurpose functions are a bit of a no-no anyways. :coffee:
hana::Foldableis known at compile-time. You shouldn't need to put it in a run-time list.
enums? (I might just ask myself to reevaluate what I'm using an
enumfor and see if I can't create a class that does it at least as well and interoperates with Hana directly, but I figured I'd ask before reinventing the wheel.)