-
Key: IDL4CPP-36
-
Status: closed
-
Source: Remedy IT ( Johnny Willemsen)
-
Summary:
The spec says for bounded strings " For interoperability purposes, implementers shall always define omg::types::bounded_string<N>, which may be declared as an alias to std::string". There is a problem when a bounded string is mapped to just a typedef/using of a std::string. At that moment it is not a distinct type so the traits will not work, as example, when defining this IDL
typedef string<5> bounded_bar1;
typedef string<5> bounded_bar2;And both map to just std::string, the following code will not work correctly
if (traits<Test::bounded_bar>::is_bounded ()) {}
if (traits<Test::bounded_bar>::bound () == 5) {} -
Reported: IDL4-CPP 1.0b1 — Thu, 25 Jan 2024 12:15 GMT
-
Disposition: Resolved — IDL4-CPP 1.0b2
-
Disposition Summary:
Clarify that omg::types::bounded_<type><N> shall always be defined for potential trait specializations
With this resolution, the specification makes it clear that implementers shall always define omg::types::bounded_string<N> for potential use of trait specializations.
Future versions of this spec may explore different avenues for mapping bounded strings.
-
Updated: Mon, 16 Sep 2024 14:15 GMT
IDL4CPP — Issue with mapping of bounded string and traits
- Key: IDL4CPP-36
- OMG Task Force: IDL4 to C++ Language Mapping (IDL4-CPP) 1.0 FTF