Skip to content

Commit

Permalink
update documentation about array support in llama::DE
Browse files Browse the repository at this point in the history
  • Loading branch information
bernhardmgruber committed Mar 8, 2021
1 parent 023ca3f commit 8858696
Showing 1 changed file with 5 additions and 8 deletions.
13 changes: 5 additions & 8 deletions docs/pages/domains.rst
Original file line number Diff line number Diff line change
Expand Up @@ -91,18 +91,15 @@ A datum domain itself is just a :cpp:`DatumStruct` (or a fundamental type), as s
llama::DE<alpha, char>
>;

A :cpp:`DatumArray` is essentially a :cpp:`DatumStruct` with multiple :cpp:`DatumElement`\ s of the same type.
E.g. :cpp:`DatumArray<float, 4>` is the same as
One-dimensional arrays of compile-time extent are also supported as arguments to :cpp:`llama::DE`, but not to :cpp:`llama::DatumElement`.
Such arrays are expanded into a :cpp:`DatumStruct` with multiple :cpp:`DatumElement`\ s of the same type.
E.g. :cpp:`llama::DE<Tag, float[4]>` is expanded into

.. code-block:: C++

llama::DS<
llama::DE<Tag, llama::DS<
llama::DE<llama::Index<0>, float>,
llama::DE<llama::Index<1>, float>,
llama::DE<llama::Index<2>, float>,
llama::DE<llama::Index<3>, float>
>

LLAMA also defines a shortcuts for a datum array:

* :cpp:`llama::DatumArray` → :cpp:`llama::DA`
>>

0 comments on commit 8858696

Please sign in to comment.