Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Valued Contributor III
8 Views

"global" !DEC$ ATTRIBUTES STDCALL

In another thread we were looking at OpenGL (GLU) interfaces and I was looking at one of my own API interface modules. This module uses  BIND(C,name='xxxx') and in every interface we have "!DEC$ ATTRIBUTES STDCALL :: Func_or_sub_name. It occurred that is would be much neater and easier to have a global STDCALL attribute for the source file (or module scope) but is would seem this is not an option.

You can have !DEC$ ATTRIBUTES STDCALL :: name1, name2, name3 but that is a worse option in terms of code maintenance.

Is there any way of doing this? I would not do it via compiler option as I think that is quite error prone method.

0 Kudos
1 Reply
8 Views

No, it's not an option. I

No, it's not an option. I think that the general usefulness of such a thing is minimal, even more so as 32-bit support starts to disappear. How often would you use this outside of Windows API declarations? Note that we do now support ATTRIBUTES STDCALL combined with BIND(C).

Retired 12/31/2016
0 Kudos