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 compilation with intel compilers (ICC/ICPC) v14.0 #882

Closed
wants to merge 2 commits into from

Conversation

Luthaf
Copy link
Contributor

@Luthaf Luthaf commented Sep 26, 2018

The auto change was a warning

warning #3373: nonstandard use of "auto" to both deduce the type from an initializer and to announce a trailing return type
    auto begin = format_str.data(), end = begin + format_str.size();

The explicit change was an error

error: "explicit" is not allowed
    explicit operator String() const { return String("foo", 3u); }

@@ -1577,7 +1577,7 @@ struct explicitly_convertible_to_string_like {
typename String,
typename = typename std::enable_if<
std::is_constructible<String, const char*, std::size_t>::value>::type>
explicit operator String() const { return String("foo", 3u); }
operator String() const { return String("foo", 3u); }
Copy link
Contributor

Choose a reason for hiding this comment

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

explicit is required here. Please use FMT_EXPLICIT instead.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Oh, yeah, this makes sense. Corrected!

@@ -89,7 +89,8 @@
# endif
#endif

#if FMT_HAS_FEATURE(cxx_explicit_conversions) || FMT_MSC_VER >= 1800
#if FMT_HAS_FEATURE(cxx_explicit_conversions) || \
FMT_GCC_VERSION >= 405 || FMT_MSC_VER >= 1800
Copy link
Contributor Author

Choose a reason for hiding this comment

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

I used https://en.cppreference.com/w/cpp/compiler_support to check for the GCC version

@Luthaf
Copy link
Contributor Author

Luthaf commented Sep 27, 2018

Travis is done, but did not update the commit status, weird =/

@vitaut
Copy link
Contributor

vitaut commented Sep 27, 2018

Merged in e864acf, thanks!

@vitaut vitaut closed this Sep 27, 2018
@Luthaf Luthaf deleted the fix-icc-14 branch September 27, 2018 15:36
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