mirror of
https://github.com/mirkobrombin/raven.git
synced 2026-10-28 21:25:06 +00:00
19 lines
368 B
C
19 lines
368 B
C
typedef unsigned int (*callback_fn)(unsigned int);
|
|
|
|
__declspec(dllimport) unsigned int Dispatch(callback_fn function, unsigned int value);
|
|
|
|
static unsigned int leaf(unsigned int value)
|
|
{
|
|
return value * 2;
|
|
}
|
|
|
|
static unsigned int nested(unsigned int value)
|
|
{
|
|
return Dispatch(leaf, value + 3) + 5;
|
|
}
|
|
|
|
unsigned int raven_entry(void)
|
|
{
|
|
return Dispatch(nested, 7) + 1;
|
|
}
|