cling
cling copied to clipboard
Variable template instantiation does not create static constexpr member
This breaks ROOT::RDataFrame, among other things.
In RDataFrame's case TypeTraits<ArgTypes>::list_size does not exist.
Even though the static member exists in TypeTraits.hxx:
namespace ROOT {
/// ROOT type_traits extensions
namespace TypeTraits {
/// Lightweight storage for a collection of types.
/// Differently from std::tuple, no instantiation of objects of stored types is performed
template <typename... Types>
struct TypeList {
static constexpr std::size_t list_size = sizeof...(Types);
};
} // end ns TypeTraits
Reproduce with:
ROOT::RDataFrame d(50);
int i = 0;
d.Define("test", [&i]() { return (double)i; }).Filter("test > 10");
Or with:
ROOT::RDataFrame d(50);
int i = 0;
d.Define("test", [&i]() { return (double)i; });
d.Filter([](double test){ return test > 0;}, {"test"});
Exists both on latest swan

and local archlinux:
Name : root
Version : 6.22.06-2
It needed
#include "TROOT.h"
in the macro .C file for some reason. Confusing. Never written in the reference docs seemingly.
@Eximius please marked this issue as resolved if you've fixed your problem
Seems to work with latest master, please reopen if you reproduce the failure, thanks.