Closed Weeena closed 7 years ago
I'd see the name as an override, and if you declare it you have to use it. I've found it best to just use the type and not declare a meta-class name unless necessary.
Ok, then the optional name is an override name rather than an alias name. And I will definitely stick to the type name and not declare a meta-class name unnecessary.
If I have declared a class to ponder with an alias name like this
should then both methods work to retrieve the class:
Currently, only the retrieval by name works. The first call with
classByType<MyType>()
leads to a runtime error because the class with name"MyType"
is not found (which was established as static name for typeMyType
with thePONDER_TYPE
macro).So my question is: Should this work as expected or are my expectations wrong?
(Side note: It is not an urgent issue for me since up to now all my classed are declared without an alias name, and in that case everything works fine.)