Article View: comp.std.c
Article #2039Re: #pragma
From: Rahul Dhesi
Date: Wed, 05 Dec 1990 19:42
Date: Wed, 05 Dec 1990 19:42
26 lines
1519 bytes
1519 bytes
In <9012050330.AA04857@decpa.pa.dec.com> diamond@tkou02.enet.dec.com
("diamond@tkovoa") writes:
>In that case, why should unrecognized #pragmas be ignored?
A minor mistake.
Pragmas allow one to escape from the confines of the standard. Such
escapes should always be done under the full control of the user. A
good way to implement pragmas is to require that all pragmas that will
be recognized by a compiler be listed in a file, and any pragma not in
that file result in a warning. This will minimize the probability
that a switch in compilers, or a revision in the names of pragmas
interpreted by a compiler, won't cause surprises.
The current situation, such that some pragmas are silently obeyed,
while others are silently ignored, is a disaster waiting to happen.
/* The "unroll-loop" pragma force loop unrolling, so our process
will react well within the 0.5 milliseconds needed to avoid a
nuclear explosion. */
#pragma unrolll_loop /* Darn! Got to get that keybounce fixed */
--
Rahul Dhesi <dhesi%cirrusl@oliveb.ATC.olivetti.com>
UUCP: oliveb!cirrusl!dhesi
Technical Details
Message-ID:
<2772@cirrusl.UUCP>Path:
arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!usc!apple!olivea!tymix!cirrusl!sunstorm!dhesiReferences:
<9012050330.AA04857@decpa.pa.dec.com>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!usc!apple!olivea!tymix!cirrusl!sunstorm!dhesi From: dhesi%cirrusl@oliveb.ATC.olivetti.com (Rahul Dhesi) Newsgroups: comp.std.c Subject: Re: #pragma Message-ID: <2772@cirrusl.UUCP> Date: 5 Dec 90 19:42:15 GMT References: <9012050330.AA04857@decpa.pa.dec.com> Sender: news@cirrusl.UUCP Organization: Cirrus Logic Inc. Lines: 26