From: Bryan@SU-SIERRA.ARPA (Doug Bryan)
Subject: pragmas
Date: Wed, 7-May-86 00:55:53 EDT [thread overview]
Date: Wed May 7 00:55:53 1986
Message-ID: <8605100458.AA10347@ucbvax.Berkeley.EDU> (raw)
Sam,
Yes, the language-defined (Appendix B) pragmas need not be "recognized"
by an implementation, yet all language-defined pragmas must be "supported"
by an implementation. Here "recognized" means implemented, the semantics
hold; "supported" simply means that the existance of a language-defined
pragma cannot make a compilation unit syntactically invalid. This is my
interpretation. Let me tell you why:
2.8(8) ... language-defined pragmas "must be supported by every
implementation."
2.8(11) "It is recommended (but not required) that implementations issue
warnings for pragmas that are not recognized and therefore ignored."
Par (11) says that an implementation may "ignore" a pragma. So here in
2.8 we see that there must be a difference between 'not support' and "ignore".
11.7(1) "The presence of a SUPPRESS pragma give permission to an implementation
to omit curtain run-time checks."
11.7(3) "The permission to omit the given check extends ..."
11.7(20) "For curtain implementations, it may be impossible or too costly
to suppress curtain checks. The corresponding SUPPRESS pragma
can be ignored."
6.3.2(1) "The pragma INLINE is used to indicate that inline expansion of the
subprogram body is desired for every call to each of the named
subprograms."
6.3.2(4) "For each call of the named subprograms, an implementation is free
to follow or to ignore the recommendation expressed by the pragma."
It seems clear that the pragmas SUPPRESS and INLINE are optional.
In the explination of other pragmas, for instance SHARED 9.11(9-11),
the word "must" often appears and the reader does not get any indication
that the pragma is optional. In such cases, one must revert back to
2.8(11). In these cases, 2.8(11) has precedence, and thus all pragmas
are optional yet "supported".
doug
-------
reply other threads:[~1986-05-07 4:55 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox