Bikeshed datum and array domain definition #176
Unanswered
bernhardmgruber
asked this question in
Q&A
Replies: 1 comment 1 reply
-
In a recent discussion with @jblomer we found |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Defining the datum domain in LLAMA is quite verbose and feels alien. We will eventually get around this with proper reflection in C++, but this will still take time. Until then I would like to make the user experience as little painful and as understandable as possible. Currently, a datum domain could be defined like this:
We already provide the aliases
llama::DS
,llama::DE
andllama::DA
forllama::DatumStruct
,llama::DatumElement
andllama::DatumArray
to take out some of the verbosity. For static arrays I even implemented a shorthand notation, e.g.bool[4]
. I still don't like the the abbreviations and considered renaming them at multiple occations:Instead of
Member
I also consideredDataMember
,Element
orAttribute
.The array domain is later defined using a type holding the dimensions and an instance holding the runtime sizes:
I am kind of happy with the way this works, but I am unsure if
ArrayDomain
is the right name. I consideredIndexSpace
at some point, because it defines what indices are allowed to access allama::View
. However, we can also see the tag types of the datum domain as (compile time) indices, so the array domain does not solely define the index space.I am happy for any feedback on the current choice of names! Thank you!
Beta Was this translation helpful? Give feedback.
All reactions