From: Mikko Rasa Date: Mon, 3 Jun 2019 11:50:39 +0000 (+0300) Subject: Fix formatted output operator detection in lexicalcast.h X-Git-Url: http://git.tdb.fi/?a=commitdiff_plain;h=4f04dc8e2dcb48d524c141cb14ce05b655608454;p=libs%2Fcore.git Fix formatted output operator detection in lexicalcast.h Since it was using a default-constructed value as part of the test expression, it would fail to detect the operator for classes that are not default-constructable. --- diff --git a/source/strings/lexicalcast.h b/source/strings/lexicalcast.h index 6fe3cb3..22b45e8 100644 --- a/source/strings/lexicalcast.h +++ b/source/strings/lexicalcast.h @@ -97,7 +97,7 @@ struct CheckFormattedOutput: Sfinae { static std::ostream &s; template - static Yes f(int (*)[sizeof(s<(s))]); using Sfinae::f; };