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 concept requirements #2513

Merged
merged 4 commits into from
Jan 23, 2023
Merged

Fix concept requirements #2513

merged 4 commits into from
Jan 23, 2023

Conversation

chrisrichardson
Copy link
Contributor

@chrisrichardson chrisrichardson commented Jan 23, 2023

Currently gcc-12 is showing warnings about "requires" statements, which this fixes.

See Issue #2507

@@ -769,7 +770,8 @@ void pack_coefficients(const Form<T>& form, IntegralType integral_type, int id,
{
case IntegralType::cell:
{
auto fetch_cell = [](auto& entity) { return entity.front(); };
auto fetch_cell
Copy link
Member

Choose a reason for hiding this comment

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

Are the changes removing auto intended?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It wasn't compiling. I think because auto& is wrong, but auto seems OK.

Copy link
Member

Choose a reason for hiding this comment

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

I'm not sure it's wrong.

Have you checked performance? This is a critical part of the code - is the pass by value an issue?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Not an issue for std::span

Copy link
Member

Choose a reason for hiding this comment

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

Did you test? It brings in a copy of the size at every call.

@chrisrichardson chrisrichardson merged commit 8177090 into main Jan 23, 2023
@chrisrichardson chrisrichardson deleted the chris/fix-gcc12-requires branch January 23, 2023 21:03
@garth-wells garth-wells added the housekeeping Tidying and style improvements label Feb 10, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
housekeeping Tidying and style improvements
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants