derived.h
Go to the documentation of this file.
1 #pragma once
2 
4 {
5 
6  template <class DerivedT, class ThisT>
7  DerivedT&
8  derived(ThisT* t)
9  {
10  return static_cast<DerivedT&>(*t);
11  }
12 
13  template <class DerivedT, class ThisT>
14  const DerivedT&
15  derived(const ThisT* t)
16  {
17  return static_cast<const DerivedT&>(*t);
18  }
19 
20 } // namespace armarx::armem::base::detail
armarx::armem::base::detail
Definition: AronTyped.cpp:5
armarx::armem::base::detail::derived
DerivedT & derived(ThisT *t)
Definition: derived.h:8