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 for older versions of intel compiler #1518

Merged
merged 1 commit into from
Jan 15, 2020
Merged

Conversation

gsjaardema
Copy link
Contributor

The intel-17 and intel-18 compilers seem to require that u be const:

/src/fmt/format.h(226): warning #437: reference to local variable of enclosing function is not allowed
        char data[sizeof(u)];

If u is declared as const auto u =1u instead of just auto u=1u, the file compiles with no warnings.

I agree that my contributions are licensed under the {fmt} license, and agree to future changes to the licensing.

The intel-17 and intel-18 compilers seem to require that `u` be `const`:
```
/src/fmt/format.h(226): warning fmtlib#437: reference to local variable of enclosing function is not allowed
        char data[sizeof(u)];
```
If `u` is declared as `const auto u =1u` instead of just `auto u=1u`, the file compiles with no warnings.
@vitaut vitaut merged commit ae3ea15 into fmtlib:master Jan 15, 2020
@vitaut
Copy link
Contributor

vitaut commented Jan 15, 2020

Thanks!

@gsjaardema gsjaardema deleted the patch-4 branch August 13, 2020 20:39
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

Successfully merging this pull request may close these issues.

2 participants