C++ Logo

SG7

Advanced search

Subject: Re: members_of( namespace ).size() changes when a namespace grows ?
From: David Vandevoorde (daveed_at_[hidden])
Date: 2020-10-28 15:58:36


> On Oct 28, 2020, at 4:36 PM, Cleiton Santoia via SG7 <sg7_at_[hidden]> wrote:
>
> Sorry I didn't follow last progress in Reflection.
>
>
>
> Anybody knows if :
>
> namespace X {
> void A() {}
> }
> static_assert ( members_of( reflexpr(X) ).size() == 1 );
>
> namespace X {
> void B() {}
> }
> static_assert ( members_of( reflexpr(X) ).size() == 2 ); // <- size() changes ?
>
> does the second assert fails ?
>

No, it shouldn't fail.

        Daveed



SG7 list run by sg7-owner@lists.isocpp.org

Older Archives on Google Groups