× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



-----Message d'origine-----
[mailto:rpg400-l-bounces@xxxxxxxxxxxx] De la part de Simon Coulter

No I wasn't ... but that can hardly be the first use of RTFM
you've seen--even if not directed at you.

Nope, not in all the years I've been on this list. No, I'm not going to look it up in the archives!



Anyway, IIRC, the FM says that the special value *OMIT will
be passed.

Not really. It says that a null address will be passed
(paraphrasing but that's the gist of it).

Just re - read :

When OPTIONS(*OMIT) is specified, then the value *OMIT is allowed for that
parameter.


I guess that by passing *OMIT, I am expressly stating that
the caller
must not use the parameter. So in my view this seems to be the best
way.

No, you are expressly saying the receiver must not use the parameter.
Sorry, that's what I meant.


So, back to my problem.

I've a program

Parm1 CONST
Parm2 CONST
Parm3 CONST
Parm4 CONST
Parm5 CONST
Parm6
Parm7

Parameters 4 5 and 6 are always passed, 6 being an error message. Parm7 represents an optional pointer to data structure. As parameters 1 to 3 aren't always needed I wanted to use *OMIT on these. I have *NOPASS on Parm7. The program knows when which parameters are supposed to be present. As this may be called by many other programs I thought calling like this :

MyPgm ( *OMIT :
*OMIT :
*OMIT :
Parm4 :
Parm5 :
Parm6 );
OR

MyPgm ( *OMIT :
*OMIT :
*OMIT :
Parm4 :
Parm5 :
Parm6 :
Parm7 );

Would make it perfectly clear that parameters 1 to 3 were not to be used.

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.