Awful name, I know. I will illustrate:
template <typename ValType> struct MemMapFileHashTable : MemMapFileStructured<MemMapFileHashTable<ValType>::kvp> {
struct kvp {
uint32_t key;
ValType val;
};
MemMapFileHashTable(const char* fileName, bool write = false, int64_t chunkB = 65536) : MemMapFileStructured(fileName, write, chunkB) { }
};
So the idea is that I create a hash table with a specific ValType, which in turn has kvp with a specific ValType.
To use a class that inherits, I need to set kvp as a type specifier, however, since kvp is declared inside the hash table class, it will not let me. Is there any way to convince him otherwise?
I could just create an instance of MemMapFileStructured inside the hash table, I suppose, but this will be the fifth consecutive inheritance in the class lines that I built, and I don't want to break my cast.