Projekt

Allgemein

Profil

Feature #794

Von Maximilian Seesslen vor 1 Tag aktualisiert

Quite dirty. Kokon is using this for vagus.

<pre><code class="cpp">

#define PSEUDO_VIRTUAL_RET_PARAM( CLASS_A, CLASS_B, FUNCTION, RET, PARAM ) \
RET CLASS_A::FUNCTION( PARAM val ) \
{ \
return( static_cast<CLASS_B *>(this)->FUNCTION( val ) ); \
}

#define PSEUDO_VIRTUAL_RET( CLASS_A, CLASS_B, FUNCTION, RET ) \
RET CLASS_A::FUNCTION( ) \
{ \
return( static_cast<CLASS_B *>(this)->FUNCTION( ) ); \
}

#define PSEUDO_VIRTUAL_VOID( CLASS_A, CLASS_B, FUNCTION ) \
void CLASS_A::FUNCTION( ) \
{ \
static_cast<CLASS_B *>(this)->FUNCTION( ); \
return; \
}

</code></pre>

Zurück