Topic: RFI: A using-declaration shall not name a template-id.
Author: Valentin Bonnard <Bonnard.V@wanadoo.fr>
Date: 1999/09/19 Raw View
Hyman Rosen wrote:
> Valentin Bonnard <Bonnard.V@wanadoo.fr> writes:
> > The problem (my problem?) is that other opinions have been
> > expressed in this ng, and that it isn't very clear to me
> > what the intent is. And the use of the verb to name seems
> > awfully unclear in an IS.
> Well, the job of a using-declaration is to bring a name into the
> local scope, so it seems perfectly clear to me that the thing the
> using-declaration names is the name!
Thank you very much for justifying the need for my RFI for me.
--
Valentin Bonnard
[ 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: Hyman Rosen <hymie@prolifics.com>
Date: 1999/09/17 Raw View
Valentin Bonnard <Bonnard.V@wanadoo.fr> writes:
> The problem (my problem?) is that other opinions have been
> expressed in this ng, and that it isn't very clear to me
> what the intent is. And the use of the verb to name seems
> awfully unclear in an IS.
Well, the job of a using-declaration is to bring a name into the
local scope, so it seems perfectly clear to me that the thing the
using-declaration names is the name!
[ 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: Valentin Bonnard <Bonnard.V@wanadoo.fr>
Date: 1999/09/16 Raw View
This is a request for interpretation. Moderator: please
forward to the core issues list maintainer.
7.3.3/5 says:
> A using-declaration shall not name a template-id.
What does this means ? Could the committee elaborate on the
verb ``to name'' ?
Then text goes on with examples which contains template-ids.
Does ``names'' means ``contains'' ? Does it mean ``is'' ?
Specifically, is the following ill-formed ? (If so, could
the committee provide a short rational ?)
template <typename T>
struct base {
void bar ();
};
struct der : base<int>
{
using base<int>::bar; // ill-formed ?
void bar (int);
};
--
Valentin Bonnard
[ 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: Hyman Rosen <hymie@prolifics.com>
Date: 1999/09/17 Raw View
Valentin Bonnard <Bonnard.V@wanadoo.fr> writes:
> 7.3.3/5 says:
> > A using-declaration shall not name a template-id.
> What does this means ? Could the committee elaborate on the
> verb ``to name'' ?
What's the problem? 7.3.3/1 gives the syntax for a using-declaration,
which always involes an unqualified-id, which is the name named by the
using-declaration. 5.1/1 gives the syntax for an unqualified-id, one
possibility of which is a template-id. 7.3.3/5 then restricts that
this form of unqualified-id is not legal in a using-declaration, and
gives specific examples of the illegal usage.
---
[ 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: Valentin Bonnard <Bonnard.V@wanadoo.fr>
Date: 1999/09/17 Raw View
Hyman Rosen wrote:
> Valentin Bonnard <Bonnard.V@wanadoo.fr> writes:
> > 7.3.3/5 says:
> > > A using-declaration shall not name a template-id.
> > What does this means ? Could the committee elaborate on the
> > verb ``to name'' ?
>
> What's the problem? 7.3.3/1 gives the syntax for a using-declaration,
> which always involes an unqualified-id, which is the name named by the
> using-declaration. 5.1/1 gives the syntax for an unqualified-id, one
> possibility of which is a template-id. 7.3.3/5 then restricts that
> this form of unqualified-id is not legal in a using-declaration, and
> gives specific examples of the illegal usage.
The problem (my problem?) is that other opinions have been
expressed in this ng, and that it isn't very clear to me
what the intent is. And the use of the verb to name seems
awfully unclear in an IS.
--
Valentin Bonnard
---
[ 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 ]