mirror of
https://git.suyu.dev/suyu/Yucom.git
synced 2026-01-02 04:34:29 +01:00
vrclient: Generate call_flat_method() functions.
In order to remove hardcoded limit for parameter count in C API functions.
This commit is contained in:
parent
23ffdc5ec8
commit
d687b83fcb
4 changed files with 220 additions and 66 deletions
|
|
@ -51,18 +51,7 @@ static const struct thunk thunk_template =
|
|||
|
||||
typedef void (*pfn_call_flat_method)(void);
|
||||
|
||||
extern void call_flat_method3(void);
|
||||
extern void call_flat_method4(void);
|
||||
extern void call_flat_method9(void);
|
||||
|
||||
static inline pfn_call_flat_method get_call_flat_method_pfn( int param_count )
|
||||
{
|
||||
if (param_count <= 3)
|
||||
return call_flat_method3;
|
||||
if (param_count <= 4)
|
||||
return call_flat_method4;
|
||||
return call_flat_method9;
|
||||
}
|
||||
extern pfn_call_flat_method get_call_flat_method_pfn( int param_count );
|
||||
|
||||
static inline void init_thunk( struct thunk *thunk, void *this, void *proc, int param_count )
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue