Topic: Implementation limits.
Author: "greg" <dont@spam.me>
Date: 1998/03/11 Raw View
James Kuyper <kuyper@wizard.net> wrote in article
<3506AF2B.2781@wizard.net>...
> My copy of the C9X standard ( I don't know if the wording was similar in
> C89) says:
>
> | 5.2.4.1 Translation limits
> |
> | 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:
>
> In contrast, the C++ standard contains the famous "resource limits"
> exemption:
>
> [Section 1.3]
> |2. Every conforming C++ implementation shall, within its resource
limits,
> | accept and correctly execute well-formed C++ programs, ...
>
> and Annex AA, where the recommended minimum numerical limits are given,
> says:
> ...
> | ... these quantities
> | are only guidelines and do not determine compliance.
>
> Why are the C++ requirements so much weaker? ...
This was an extremely controversial topic for the committee. As I
recall there was a real fear that any fixed limits we placed in the
standard would turn into limits on portable programs, when what we
wanted to enourage were implementations that had no arbitrary limits.
The annex AA was a compromise between those who demanded C-style
limits and those who abhored them.
Greg Colvin
---
[ comp.std.c++ is moderated. To submit articles, try just posting with ]
[ your news-reader. If that fails, use mailto:std-c++@ncar.ucar.edu ]
[ --- Please see the FAQ before posting. --- ]
[ FAQ: http://reality.sgi.com/austern_mti/std-c++/faq.html ]
Author: James Kuyper <kuyper@wizard.net>
Date: 1998/03/11 Raw View
My copy of the C9X standard ( I don't know if the wording was similar in
C89) says:
| 5.2.4.1 Translation limits
|
| 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:
In contrast, the C++ standard contains the famous "resource limits"
exemption:
[Section 1.3]
|2. Every conforming C++ implementation shall, within its resource limits,
| accept and correctly execute well-formed C++ programs, ...
and Annex AA, where the recommended minimum numerical limits are given,
says:
| ... Every
| implementation shall document those limitations where known. This
| documentation may cite fixed limits where they exist, say how to com-
| pute variable limits as a function of available resources, or say that
| fixed limits do not exist or are unknown.
and
| ... these quantities
| are only guidelines and do not determine compliance.
Why are the C++ requirements so much weaker? Of course, the "one
program" required by the C9X version might not exhibit any observable
behavior, allowing its 'execution' to be a no-op. However, for any
serious implementation, the C9X requirements are significantly more
stringent, despite the fact that the Annex AA minima for C++ are much
larger.
---
[ comp.std.c++ is moderated. To submit articles, try just posting with ]
[ your news-reader. If that fails, use mailto:std-c++@ncar.ucar.edu ]
[ --- Please see the FAQ before posting. --- ]
[ FAQ: http://reality.sgi.com/austern_mti/std-c++/faq.html ]