forked from M-Labs/nac3
core/irrt: add List
Needed for implementing np_array()
This commit is contained in:
parent
9c5273ae09
commit
da23bb1417
@ -1,5 +1,6 @@
|
|||||||
#include <irrt/exception.hpp>
|
#include <irrt/exception.hpp>
|
||||||
#include <irrt/int_types.hpp>
|
#include <irrt/int_types.hpp>
|
||||||
|
#include <irrt/list.hpp>
|
||||||
#include <irrt/math_util.hpp>
|
#include <irrt/math_util.hpp>
|
||||||
#include <irrt/ndarray/basic.hpp>
|
#include <irrt/ndarray/basic.hpp>
|
||||||
#include <irrt/ndarray/def.hpp>
|
#include <irrt/ndarray/def.hpp>
|
||||||
|
19
nac3core/irrt/irrt/list.hpp
Normal file
19
nac3core/irrt/irrt/list.hpp
Normal file
@ -0,0 +1,19 @@
|
|||||||
|
#pragma once
|
||||||
|
|
||||||
|
#include <irrt/int_types.hpp>
|
||||||
|
#include <irrt/slice.hpp>
|
||||||
|
|
||||||
|
namespace
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* @brief A list in NAC3.
|
||||||
|
*
|
||||||
|
* The `items` field is opaque. You must rely on external contexts to
|
||||||
|
* know how to interpret it.
|
||||||
|
*/
|
||||||
|
template <typename SizeT> struct List
|
||||||
|
{
|
||||||
|
uint8_t *items;
|
||||||
|
SizeT len;
|
||||||
|
};
|
||||||
|
} // namespace
|
Loading…
Reference in New Issue
Block a user