A C++ template library for embedded applications
Designed and maintained by
Aster Consulting Ltd


A few useful utility functions.

template <typename T, typename U = T>
T exchange(T& object, const U& new_value)
Copies the new value to object and returns the old value.
Note: This is not an atomic operation.

template <typename T>
typename etl::add_const<T>::type& as_const(T& t)
Returns a value of type T as a const T.