开发者

How to declare an __stdcall function pointer

开发者 https://www.devze.com 2023-02-16 13:06 出处:网络
I tried this typedef void (* __stdcall MessageHandler)(const Task*); This compiles but gives me this warning (VS2003):

I tried this

typedef void (* __stdcall MessageHandler)(const Task*);

This compiles but gives me this warning (VS2003):

warning C4229: anachronism used : modifiers on data are ignored

I want to declare a pointer t开发者_JAVA技巧o a function with stdcall calling convention? What am I doing wrong?


As MSDN says, the correct way to write this is

typedef void (__stdcall *MessageHandler)(const Task*);
0

精彩评论

暂无评论...
验证码 换一张
取 消