-
Key: CPP1116-7
-
Status: closed Implementation work Blocked
-
Source: Remedy IT ( Johnny Willemsen)
-
Summary:
The IDL to C++11 tries to prevent the user from remembering all kind of special naming rules. The spec now uses "<Bitmask>Bits" but that is something we want to prevent, we propose to use a IDL::traits<>::bits which can be used as a generic way to use this special "<Bitmask>Bits" type in code. It could happen that there is also a user type "<Bitmask>Bits" in IDL, how is this now handled? When IDL::traits<>::bits is used the naming of the implied type is an implementation decision
Also a C++11 strong enum should be used instead of an old enum to prevent the enumerator values to pollute the containing namespace, the current approach doesn't work when there are 2 bitmasks with the same set of enumerators, the code below doesn't compile
enum MyBitMaskBits : std::uint8_t
{ flag0 = 1, flag1 = 2, flag4 = 16, f6 = 64};
enum MyBitMask2Bits : std::uint8_t { flag0 = 1, flag1 = 2, flag4 = 16, f6 = 64};
-
Reported: CPP11 1.5 — Thu, 22 Apr 2021 09:08 GMT
-
Disposition: Resolved — CPP 1.6
-
Disposition Summary:
Update bitmask IDL traits
Update IDL traits for bitmask types.
-
Updated: Thu, 31 Mar 2022 19:32 GMT
CPP1116 — IDL::traits missing for enum type for bitmask and use a C++11 strong enum
- Key: CPP1116-7
- OMG Task Force: IDL to C++11 1.6 RTF