Date: Mon, 11 Nov 2024 14:01:40 +0200
On Mon, 11 Nov 2024 at 13:54, Peter Dimov <pdimov_at_[hidden]> wrote:
>
> Ville Voutilainen wrote:
> > On Mon, 11 Nov 2024 at 13:30, Peter Dimov <pdimov_at_[hidden]> wrote:
> > >
> > > Ville Voutilainen wrote:
> > > > Perhaps we should have reflection queries for such properties,
> > > > instead of relying on access-bypassing reflection of privates.
> > >
> > > Seeing the entire class definition is not access. Access is access.
> >
> > I wonder whether you're talking about object access. Access controls in C++,
> > however, cover more than that.
> > You can't programmatically form well-formed dependencies to inaccessible
> > parts of a class definition, including, for example, nested types that are private.
>
> No? https://godbolt.org/z/833hc99E4
..unless exposed by something accessible, sure. I trust I don't need
to godbolt for you what happens with
class X
{
class Nested{};
};
X::Nested xn;
>
> Ville Voutilainen wrote:
> > On Mon, 11 Nov 2024 at 13:30, Peter Dimov <pdimov_at_[hidden]> wrote:
> > >
> > > Ville Voutilainen wrote:
> > > > Perhaps we should have reflection queries for such properties,
> > > > instead of relying on access-bypassing reflection of privates.
> > >
> > > Seeing the entire class definition is not access. Access is access.
> >
> > I wonder whether you're talking about object access. Access controls in C++,
> > however, cover more than that.
> > You can't programmatically form well-formed dependencies to inaccessible
> > parts of a class definition, including, for example, nested types that are private.
>
> No? https://godbolt.org/z/833hc99E4
..unless exposed by something accessible, sure. I trust I don't need
to godbolt for you what happens with
class X
{
class Nested{};
};
X::Nested xn;
Received on 2024-11-11 12:01:55