On Sun, 05 Dec 2004 15:50:05 +0100, drkm :
En regard de ma réponse à Fabien, ne serait-il pas évident
d'interdir cette construction ?
Yep. D'autant que l'utilité d'introduire les VLA en C++, c'est la
compatibilité avec des headers écrits en C -- et de tels headers ne
risquent pas de parler d'héritage.
On Sun, 05 Dec 2004 15:50:05 +0100, drkm <usenet.fclcxx@fgeorges.org>:
En regard de ma réponse à Fabien, ne serait-il pas évident
d'interdir cette construction ?
Yep. D'autant que l'utilité d'introduire les VLA en C++, c'est la
compatibilité avec des headers écrits en C -- et de tels headers ne
risquent pas de parler d'héritage.
On Sun, 05 Dec 2004 15:50:05 +0100, drkm :
En regard de ma réponse à Fabien, ne serait-il pas évident
d'interdir cette construction ?
Yep. D'autant que l'utilité d'introduire les VLA en C++, c'est la
compatibilité avec des headers écrits en C -- et de tels headers ne
risquent pas de parler d'héritage.
drkm writes:
| Fabien LE LEZ writes:
| > On Sun, 05 Dec 2004 06:10:20 +0100, drkm
| > :
| >> struct B
| >> {
| >> char tableau [*]; // Pas sûr de la syntaxe
| >> int i;
| > Illégal, si j'en crois James : "Une VLA peut, par exemple, être le
| > dernier élément d'un struct."
| Je viens de vérifier dans la norme. 6.7.2.1/2 dit :
| A structure or union shall not contain a member with incomplete
| or function type [...], except that the last member of a
| structure with more than one named member may have incomplete
| array type; such a structure (and any union containing, possibly
| recursively, a member that is such a structure) shall not be a
| member of a structure or an element of an array.
| Il me semble que la transposition naturelle en C++ serait bien
| d'interdir l'héritage : « such a structure [...] shall not be a
| member of a structure ».
La transposition naturelle en C+ serait de banir cette abomination.
drkm <usenet.fclcxx@fgeorges.org> writes:
| Fabien LE LEZ <gramster@gramster.com> writes:
| > On Sun, 05 Dec 2004 06:10:20 +0100, drkm
| > <usenet.fclcxx@fgeorges.org>:
| >> struct B
| >> {
| >> char tableau [*]; // Pas sûr de la syntaxe
| >> int i;
| > Illégal, si j'en crois James : "Une VLA peut, par exemple, être le
| > dernier élément d'un struct."
| Je viens de vérifier dans la norme. 6.7.2.1/2 dit :
| A structure or union shall not contain a member with incomplete
| or function type [...], except that the last member of a
| structure with more than one named member may have incomplete
| array type; such a structure (and any union containing, possibly
| recursively, a member that is such a structure) shall not be a
| member of a structure or an element of an array.
| Il me semble que la transposition naturelle en C++ serait bien
| d'interdir l'héritage : « such a structure [...] shall not be a
| member of a structure ».
La transposition naturelle en C+ serait de banir cette abomination.
drkm writes:
| Fabien LE LEZ writes:
| > On Sun, 05 Dec 2004 06:10:20 +0100, drkm
| > :
| >> struct B
| >> {
| >> char tableau [*]; // Pas sûr de la syntaxe
| >> int i;
| > Illégal, si j'en crois James : "Une VLA peut, par exemple, être le
| > dernier élément d'un struct."
| Je viens de vérifier dans la norme. 6.7.2.1/2 dit :
| A structure or union shall not contain a member with incomplete
| or function type [...], except that the last member of a
| structure with more than one named member may have incomplete
| array type; such a structure (and any union containing, possibly
| recursively, a member that is such a structure) shall not be a
| member of a structure or an element of an array.
| Il me semble que la transposition naturelle en C++ serait bien
| d'interdir l'héritage : « such a structure [...] shall not be a
| member of a structure ».
La transposition naturelle en C+ serait de banir cette abomination.
writes:
| Gabriel Dos Reis wrote in message
| news:...
| > drkm writes:
| > | Fabien LE LEZ writes:
| > | > On Sun, 05 Dec 2004 06:10:20 +0100, drkm
| > | > :
| > | >> struct B
| > | >> {
| > | >> char tableau [*]; // Pas sûr de la syntaxe
| > | >> int i;
| > | > Illégal, si j'en crois James : "Une VLA peut, par exemple,
être le
| > | > dernier élément d'un struct."
| > | Je viens de vérifier dans la norme. 6.7.2.1/2 dit :
| > | A structure or union shall not contain a member with incomplete
| > | or function type [...], except that the last member of a
| > | structure with more than one named member may have incomplete
| > | array type; such a structure (and any union containing,
possibly
| > | recursively, a member that is such a structure) shall not be a
| > | member of a structure or an element of an array.
| > | Il me semble que la transposition naturelle en C++ serait bien
| > | d'interdir l'héritage : « such a structure [...] shall not be a
| > | member of a structure ».
| > La transposition naturelle en C+ serait de banir cette abomination.
| Pratiquement, je crois que ce choix-là ne nous est pas ouvert.
Ah, parce que pratiquement le choix de pervertir le système de type de
C++ t'est ouvert ?
kanze@gabi-soft.fr writes:
| Gabriel Dos Reis <gdr@integrable-solutions.net> wrote in message
| news:<m3is7go6lw.fsf@uniton.integrable-solutions.net>...
| > drkm <usenet.fclcxx@fgeorges.org> writes:
| > | Fabien LE LEZ <gramster@gramster.com> writes:
| > | > On Sun, 05 Dec 2004 06:10:20 +0100, drkm
| > | > <usenet.fclcxx@fgeorges.org>:
| > | >> struct B
| > | >> {
| > | >> char tableau [*]; // Pas sûr de la syntaxe
| > | >> int i;
| > | > Illégal, si j'en crois James : "Une VLA peut, par exemple,
être le
| > | > dernier élément d'un struct."
| > | Je viens de vérifier dans la norme. 6.7.2.1/2 dit :
| > | A structure or union shall not contain a member with incomplete
| > | or function type [...], except that the last member of a
| > | structure with more than one named member may have incomplete
| > | array type; such a structure (and any union containing,
possibly
| > | recursively, a member that is such a structure) shall not be a
| > | member of a structure or an element of an array.
| > | Il me semble que la transposition naturelle en C++ serait bien
| > | d'interdir l'héritage : « such a structure [...] shall not be a
| > | member of a structure ».
| > La transposition naturelle en C+ serait de banir cette abomination.
| Pratiquement, je crois que ce choix-là ne nous est pas ouvert.
Ah, parce que pratiquement le choix de pervertir le système de type de
C++ t'est ouvert ?
writes:
| Gabriel Dos Reis wrote in message
| news:...
| > drkm writes:
| > | Fabien LE LEZ writes:
| > | > On Sun, 05 Dec 2004 06:10:20 +0100, drkm
| > | > :
| > | >> struct B
| > | >> {
| > | >> char tableau [*]; // Pas sûr de la syntaxe
| > | >> int i;
| > | > Illégal, si j'en crois James : "Une VLA peut, par exemple,
être le
| > | > dernier élément d'un struct."
| > | Je viens de vérifier dans la norme. 6.7.2.1/2 dit :
| > | A structure or union shall not contain a member with incomplete
| > | or function type [...], except that the last member of a
| > | structure with more than one named member may have incomplete
| > | array type; such a structure (and any union containing,
possibly
| > | recursively, a member that is such a structure) shall not be a
| > | member of a structure or an element of an array.
| > | Il me semble que la transposition naturelle en C++ serait bien
| > | d'interdir l'héritage : « such a structure [...] shall not be a
| > | member of a structure ».
| > La transposition naturelle en C+ serait de banir cette abomination.
| Pratiquement, je crois que ce choix-là ne nous est pas ouvert.
Ah, parce que pratiquement le choix de pervertir le système de type de
C++ t'est ouvert ?
"@(none)" <""kanze"@(none)"> writes:
| Fabien LE LEZ wrote:
| > On Sun, 05 Dec 2004 15:50:05 +0100, drkm
:
| >>En regard de ma réponse à Fabien, ne serait-il pas évident
| >>d'interdir cette construction ?
| > Yep. D'autant que l'utilité d'introduire les VLA en C++, c'est la
| > compatibilité avec des headers écrits en C -- et de tels headers ne
| > risquent pas de parler d'héritage.
| C'est une des utilités, et effectivement, l'héritage n'y entre pas en
| ligne de compte.
Oui, mais et le système de type ?
"@(none)" <""kanze"@(none)"> writes:
| Fabien LE LEZ wrote:
| > On Sun, 05 Dec 2004 15:50:05 +0100, drkm
<usenet.fclcxx@fgeorges.org>:
| >>En regard de ma réponse à Fabien, ne serait-il pas évident
| >>d'interdir cette construction ?
| > Yep. D'autant que l'utilité d'introduire les VLA en C++, c'est la
| > compatibilité avec des headers écrits en C -- et de tels headers ne
| > risquent pas de parler d'héritage.
| C'est une des utilités, et effectivement, l'héritage n'y entre pas en
| ligne de compte.
Oui, mais et le système de type ?
"@(none)" <""kanze"@(none)"> writes:
| Fabien LE LEZ wrote:
| > On Sun, 05 Dec 2004 15:50:05 +0100, drkm
:
| >>En regard de ma réponse à Fabien, ne serait-il pas évident
| >>d'interdir cette construction ?
| > Yep. D'autant que l'utilité d'introduire les VLA en C++, c'est la
| > compatibilité avec des headers écrits en C -- et de tels headers ne
| > risquent pas de parler d'héritage.
| C'est une des utilités, et effectivement, l'héritage n'y entre pas en
| ligne de compte.
Oui, mais et le système de type ?