Stratax 0.4.0rc1
Loading...
Searching...
No Matches
Shape.hpp File Reference

Immutable dimension metadata and checked row-major strides. More...

#include <algorithm>
#include <cstddef>
#include <initializer_list>
#include <ostream>
#include <vector>
#include <limits>
#include <stratax/core/Buffer.hpp>
#include <stratax/exceptions/Exceptions.hpp>
#include <stratax/indexing/Normalize.hpp>
Include dependency graph for Shape.hpp:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  stratax::core::Shape
 Stores the dimensions of a multidimensional array. More...
 

Functions

std::ostream & stratax::core::operator<< (std::ostream &os, const Shape &shape)
 Writes a shape using tuple notation.
 

Detailed Description

Immutable dimension metadata and checked row-major strides.

Definition in file Shape.hpp.

Function Documentation

◆ operator<<()

std::ostream & stratax::core::operator<< ( std::ostream &  os,
const Shape &  shape 
)
inline

Writes a shape using tuple notation.

A one-dimensional shape includes a trailing comma, such as (5,), and an empty shape is written as ().

Parameters
osOutput stream receiving the representation.
shapeShape to write.
Returns
Reference to os.
Complexity
O(shape.rank()).

Definition at line 290 of file Shape.hpp.