#ifndef INDICIAL_H #define INDICIAL_H #include "Fastor/config/config.h" #include "Fastor/meta/einsum_meta.h" #include namespace Fastor { //-----------------------------------------------------------------------------------------------------------// template struct Index { static constexpr FASTOR_INDEX Size = sizeof...(All); static constexpr std::array values = {All...}; }; template constexpr FASTOR_INDEX Index::Size; template constexpr std::array Index::values; namespace internal { template struct make_index_impl; template struct make_index_impl> { using type = Index; }; } // internal template struct make_index { using type = typename internal::make_index_impl::type>::type; }; template using make_index_t = typename make_index::type; template struct OIndex : public Index { static constexpr FASTOR_INDEX Size = sizeof...(All); using parent_type = Index; }; template constexpr FASTOR_INDEX OIndex::Size; template struct to_oindex; template struct to_oindex> { using type = OIndex; }; template using to_oindex_t = typename to_oindex::type; //-----------------------------------------------------------------------------------------------------------// } // end of namespace Fastor #endif // INDICIAL_H