- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I'm linking in a library which exported externals as uppercase, and I'm linking it into a application where I need lowercase.
Seems the ALIAS declaration is the best way toresolve this (right?) but when I give statement in the subroutine where I'm making the call:
cDEC$ ALIAS internalname,'INTERNALNAME'
the compiler hates it giving me a fatal error. CanALIAS handle case changes? Where is the proper place to place this statement (I put it right before the beginning of the instructions in the subroutine making the call).
Seems the ALIAS declaration is the best way toresolve this (right?) but when I give statement in the subroutine where I'm making the call:
cDEC$ ALIAS internalname,'INTERNALNAME'
the compiler hates it giving me a fatal error. CanALIAS handle case changes? Where is the proper place to place this statement (I put it right before the beginning of the instructions in the subroutine making the call).
Link Copied
3 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
What is the error? Remember that the leading "c" should be "!" if this is free-form source.
Are you using /names:lower? I strongly recommend against that.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Quoting - rre9518
Seems the ALIAS declaration is the best way toresolve this (right?) but when I give statement in the subroutine where I'm making the call:
cDEC$ ALIAS internalname,'INTERNALNAME'
the compiler hates it giving me a fatal error. CanALIAS handle case changes? Where is the proper place to place this statement (I put it right before the beginning of the instructions in the subroutine making the call).
cDEC$ ALIAS internalname,'INTERNALNAME'
the compiler hates it giving me a fatal error. CanALIAS handle case changes? Where is the proper place to place this statement (I put it right before the beginning of the instructions in the subroutine making the call).
For the start, this should use a colon rather than a comma, i.e.
cDEC$ ALIAS internalname: 'INTERNALNAME'
See, however, also this recent thread. It seems that you need a full INTERFACE block for the library routine available to the caller, to make the line above work.
(The compiler manual has always been a bit fuzzy on rules of placement and the scope of !DEC$ATTRIBUTES. Apparently, it likes it in some places but not in others, but I've never really paid attention to it, as I've always placed them either as first line of a SUBROUTINE statement, or within an INTERFACE block).
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Actually, comma is correct for the ALIAS directive, which predates ATTRIBUTES ALIAS. The latter uses a double-colon.

Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page