Page 1 of 1

How to name own structures?

Posted: Fri Sep 28, 2018 9:24 am
by forumuser
Hi,

The Windows API normally uses something like:
_SYSTEM_PROCESS_INFO

Does it matter how I name my own structures (normally inside a module) or better:
What happens if I accidentally use the same name as a Windows API structure
(but with a completely different content)? Do they "conflict"?

Re: How to name own structures?

Posted: Fri Sep 28, 2018 9:28 am
by RSBasic
You can use your own name for the usage:

Code: Select all

Define YourOwnName._SYSTEM_PROCESS_INFO

Debug YourOwnName\...
forumuser wrote:What happens if I accidentally use the same name as a Windows API structure
Then there is a compiler error. PB tells you it's not possible:
Line x: Structure already declared: xxx (in a resident file).

Re: How to name own structures?

Posted: Fri Sep 28, 2018 12:52 pm
by forumuser
Thank you, RSBasic!