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

Fix ambiguous auto variable on gcc 7.5 #1976

Closed
wants to merge 1 commit into from

Conversation

smnogar
Copy link

@smnogar smnogar commented Jul 22, 2022

I'm running humble on an older version of embedded linux thats stuck with gcc 7.5. For some reason it didn't like this auto declaration. Could we get this pushed into rolling and humble branches?

This should resolve #1963

Signed-off-by: Steve Nogar <stephen.m.nogar.civ@army.mil>
@clalancette
Copy link
Contributor

@smnogar The linters are unhappy with the length of the line. If you fix that, we can run CI on this and get it in.

Copy link
Collaborator

@fujitatomoya fujitatomoya left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@clalancette clalancette added the more-information-needed Further information is required label Aug 18, 2022
@@ -816,7 +816,7 @@ class Client : public ClientBase
"Received invalid sequence number. Ignoring...");
return std::nullopt;
}
auto value = std::move(it->second.second);
std::optional<CallbackInfoVariant> value = std::optional<CallbackInfoVariant>{std::move(it->second.second)};

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe that if the type is explicit on the right then auto can be used on the left i.e.

Suggested change
std::optional<CallbackInfoVariant> value = std::optional<CallbackInfoVariant>{std::move(it->second.second)};
auto value = std::optional<CallbackInfoVariant>{std::move(it->second.second)};

@fujitatomoya
Copy link
Collaborator

@smnogar would you address comments above? thanks!

@clalancette
Copy link
Contributor

Since there has been no movement on this in a long time, I'm going to close this out. Feel free to respond to the comments and reopen if you are still interested in getting this in, thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
more-information-needed Further information is required
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Error During Colcon Build
4 participants