View Single Post
Old 28 February 2022, 07:55   #1
Sim085
Registered User
 
Join Date: Apr 2009
Location: N/A
Posts: 962
fd2pragma inline entry for function that returns pointer to another function

In my dynamic library I have added a function that returns a pointer to another function. The function to be returned has the following signature;
Code:
int func(int,int)
So in my clib mylib_proto file I have the following entry;
Code:
int (*getMyFunction())(int,int);
The problem is that when generating the inline, fd2pragma creates the following;
Code:
int (*)(int,int) __getFunction(__reg("a6") struct Library *)="\tjsr\t-36(a6)";
#define getFunction() __getFunction(MyLibBase)
However, for this to work I need it to generate the following syntax;
Code:
int (*__getFunction(__reg("a6") struct Library *))(int,int)="\tjsr\t-36(a6)";
#define getFunction() __getFunction(MyLibBase)
I have gone through the fd2pragma guide and I cannot find anything specific in relation to this. Anyone knows if it is possible?
Sim085 is offline  
 
Page generated in 0.04281 seconds with 11 queries