As in the title, I want to know what "(int (*) ())" in C-define-function-call means?
As an example, it looks something like this:
#define Bla(x) (Char *) read((char *(*)()) Blub, (char **) x)
or
#define XXX(nx, id) PEM_ASN1_write_bio((int (*)()) id, (char *) nx)
Thank you in advance!
Casts an argument to a pointer to a function that returns char *and accepts zero or more arguments. The second function returns int.
char *
int
You can use a program (and a website, now) called cdecl "to help with this, she says:
(char *(*)())
(int (*)())
C - , . (int (*)())
, int, external() - .
, , ,
(int (*)()) - , int (*)(). , , , " , , int ".
int (*)()
, , C: , , C, .
, , :
int (*fp)();
, , (*fp)(), int: " fp, , , int ".
(*fp)()
fp
, typecast fp , : (int (*)()).
, read Blub , char * .
read
Blub
, " , char" " char" . Bla, Bla (x), !
, PEM_ASN1_write_bio " , int". - " char". XXX (a, b) PEM_ASN1_write_bio (b, a),
Source: https://habr.com/ru/post/1723895/More articles:Как настроить туннелирование SSH для доступа к веб-серверу за брандмауэром? - puttyEclipse - ASP classic plugin - eclipseHow to access form controls for postback from a dynamically built form - c #what's the fastest way to change data passwords for an entire server farm in coldfusion? - coldfusionHow to register exceptions in C ++? - c ++Math, PDF Curves and Shading - statisticsTelerik Silverlight RadTreeview AutoRefresh - telerikDoes Symfony have any flaws? - phpWork on JIT Java Error - java.NET Framework: The "uint" argument type does not match the CLS in P / Invoke - c #All Articles