#ifdef

Here you can discuss the universal Integrated Development Environment for OpenVMS.
Post Reply
User avatar

Topic author
ajbrehm
Valued Contributor
Posts: 62
Joined: Sun Jun 16, 2019 7:55 am
Reputation: 6
Location: Zurich
Status: Offline
Contact:

#ifdef

Post by ajbrehm » Mon Aug 26, 2019 8:19 am

Can I set a #define in a VMS IDE project? I am currently using __ALPHA to mark code specific to VMS (and _WIN64 to mark code specific to Windows).

However, if in future I'll compile for Itanium and x64 as well (and to avoid confusion with Windows targets) I'd prefer an architecture-agnostic VMS define.

User avatar

martinv
Master
Posts: 102
Joined: Fri Jun 14, 2019 11:05 pm
Reputation: 0
Location: Goslar, Germany
Status: Offline
Contact:

Re: #ifdef

Post by martinv » Mon Aug 26, 2019 9:11 am

You can use __VMS, see
$ help cc Language_topics Predefined_Macros System_Identification_Macros
Working hard for something we don't care about is called stress;
working hard for something we love is called passion.
(Simon Sinek)


sergey_vorfolomeev
VSI Expert
Valued Contributor
Posts: 99
Joined: Thu Aug 22, 2019 12:17 am
Reputation: 0
Status: Offline

Re: #ifdef

Post by sergey_vorfolomeev » Mon Aug 26, 2019 11:44 pm

No, but You can do it via MMS.

User avatar

Topic author
ajbrehm
Valued Contributor
Posts: 62
Joined: Sun Jun 16, 2019 7:55 am
Reputation: 6
Location: Zurich
Status: Offline
Contact:

Re: #ifdef

Post by ajbrehm » Tue Aug 27, 2019 3:10 am

sergey_vorfolomeev wrote:
Mon Aug 26, 2019 11:44 pm
No, but You can do it via MMS.
If I do via MMS, VS Code won't know about it though.

Added in 3 minutes 27 seconds:
martinv wrote:
Mon Aug 26, 2019 9:11 am
You can use __VMS, see
$ help cc Language_topics Predefined_Macros System_Identification_Macros
Thanks!

Post Reply