home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.std.c
- Path: sparky!uunet!uunet.ca!geac!sq!msb
- From: msb@sq.sq.com (Mark Brader)
- Subject: Limits in standard (was: Maximum depth of #if preproc...)
- Message-ID: <1992Dec31.193839.1581@sq.sq.com>
- Organization: SoftQuad Inc., Toronto, Canada
- References: <1992Dec29.001933.25655@lucid.com> <C01q3x.Bpp@sneaky.lonestar.org> <1992Dec31.023341.16602@lucid.com>
- Date: Thu, 31 Dec 92 19:38:39 GMT
- Lines: 47
-
- > > > Just to put my cards on the table. X3J16/SC22 (C++ standards
- > > > committee) is sharply divided on whether to have a section on
- > > > limits. Some of us, including myself, argue that without such a
- > > > a section any limit is a bug.... we don't want to condone any limits.
- > > How can you possibly avoid some kind of limit?
- > Of course I'll run out of some resource eventually, but chances
- > are it will not translate directly into any of the numbers in
- > the standard, and it may vary from run to run. ... My contention
- > is that these limits are a quality of implementation issue rather
- > than a conformance issue.
-
- The C standard does condone limits, but the actual wording is:
-
- # The implementation shall be able to translate and execute at least
- # one program that contains at least one instance of every one of the
- # following limits. [Footnote: Implementations should avoid imposing
- # fixed translation limits wherever possible.]
-
- I believe that the intended thrust of these words in 2.2.4.1/5.2.4.1 is:
- "We would really rather that you don't fix limits at all, but IF YOU MUST,
- then those limits should be at least as large as the following."
-
- Whether fixed limits are an insupportable evil or not is a religious issue,
- on which there seem to be three points of view:
-
- 1. Fixed limits are so evil that an implementation should be forbidden
- from having them.
-
- 2. Fixed limits are so much a quality-of-implementation issue that a
- standard should not be allowed to mention them.
-
- (This is the point of view quoted above.)
-
- 3. Fixed limits are a quality-of-implementation issue, but ridiculously
- small fixed limits could constrain the programmer so much that the
- standard should prohibit them.
-
- (This is the point of view of the C standard, and mine.)
-
- Discussion of what the C++ standard should do, of course, belongs in
- comp.std.c++ and not here.
- --
- Mark Brader At any rate, C++ != C. Actually, the value of the
- SoftQuad Inc., Toronto expression "C++ != C" is implementation-defined.
- utzoo!sq!msb, msb@sq.com -- Peter da Silva
- [Actually, it's undefined.]
- This article is in the public domain.
-