Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

std::pair cannot be used with gcc 7.4 (ubuntu 18.04) #118

Open
mmaurus opened this issue Jun 24, 2019 · 1 comment
Open

std::pair cannot be used with gcc 7.4 (ubuntu 18.04) #118

mmaurus opened this issue Jun 24, 2019 · 1 comment

Comments

@mmaurus
Copy link

mmaurus commented Jun 24, 2019

The orogen generation does not work for tasks which use types based on std::pair using gcc7.4.
Error:

cannot find <TYPE> in registry (Typelib::NotFound)
    Typelib[WARN]: /usr/lib/gcc/x86_64-linux-gnu/7.4.0/../../../../include/c++/7.4.0/bits/stl_pair.h:208: ignoring /std/pair</std/basic_string</char>,/std/basic_string</char>>, it has private base classes
    Typelib[WARN]: /usr/lib/gcc/x86_64-linux-gnu/7.4.0/../../../../include/c++/7.4.0/bits/stl_vector.h:216: ignoring /std/vector</std/pair</std/basic_string</char>,/std/basic_string</char>>,/std/allocator</std/pair</std/basic_string</char>,/std/basic_string</char>>>> as its element type /std/pair</std/basic_string</char>,/std/basic_string</char>> is ignored as well
    Typelib[WARN]: ignoring <TYPE> since its field <TYPENAME> is of the ignored type /std/vector</std/pair</std/basic_string</char>,/std/basic_string</char>>,/std/allocator</std/pair</std/basic_string</char>,/std/basic_string</char>>>>
@doudou
Copy link
Contributor

doudou commented Jun 25, 2019

For a full description of what is allowed, see https://www.rock-robotics.org/rock-and-syskit/components/defining_types.html.

If you feel like implementing support for pairs, it's probably feasible. In fine, it probably "only" needs a special case to ignore std::pair base classes (which are probably zero-size) since Typelib should be capable to parse the first and second public fields. I say probably, as the C++ standard library has really non-obvious implementations of a few things.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants