gm2
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Procedure with just data type but no parameter name


From: Hưng Hưng
Subject: Procedure with just data type but no parameter name
Date: Sat, 28 Mar 2020 00:58:41 +0700

For example: PROCEDURE test(INTEGER, INTEGER): INTEGER;

Does GM2 allow this? As I know it's allowed in C.

e.g:

typedef void (*IFiis)(int, int, char*);  /* globalmotion_cb */

typedef int(*IFniiiiiiC)(Ihandle*, int, int, int, int, int, int, struct _cdCanvas*);  /* draw_cb */

I think it map to PROCEDURE TYPE in GM2. I translated the header just follow the C declaration but I don't know GM2 would allow procedure without parameter names like that. If it is required to have parameter name it will be very troublesome for me. As I have to name parameters myself and I think it's no possible way other than do everything by hand, find and replace even with the help of regex will not be possible to do that.

If it's a known limitation I think I would have to give up my translation job as so many C libraries use declaration like I mentioned above.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]