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

[error C2668] 'std::uncaught_exception' #100

Closed
JonLiu1993 opened this issue Aug 18, 2021 · 2 comments
Closed

[error C2668] 'std::uncaught_exception' #100

JonLiu1993 opened this issue Aug 18, 2021 · 2 comments

Comments

@JonLiu1993
Copy link

JonLiu1993 commented Aug 18, 2021

Hi Clickhouse Team:
When i update clickhouse-cpp to version 1.5.0. I build failed due to:

error C2668: 'signbit': ambiguous call to overloaded function

return std::signbit(v);

I have a temporary workround, I want to know if it is feasible, or do you have a better solution?

diff --git a/clickhouse/columns/decimal.cpp b/clickhouse/columns/decimal.cpp
index 7334bb1..41d43b6 100644
--- a/clickhouse/columns/decimal.cpp
+++ b/clickhouse/columns/decimal.cpp
@@ -27,7 +27,7 @@ inline bool mulOverflow(const Int128 & l, const T & r, Int128 * result)
 
 #else
 template <typename T>
-inline bool getSignBit(const T & v)
+inline bool getSignBit(const T & (long double v))
 {
     return std::signbit(v);
 }

Related pr #18330

@romanholidaypancakes
Copy link
Contributor

romanholidaypancakes commented Aug 21, 2021

hi @Enmk @filimonov , I also encountered this problem (windows vs2019), is there any good solution

related: microsoft/STL#519

@JonLiu1993 JonLiu1993 changed the title [error C4996] 'std::uncaught_exception' [error C2668] 'std::uncaught_exception' Sep 16, 2021
filimonov added a commit that referenced this issue Jan 6, 2022
apply workaround from #100 (comment)
filimonov added a commit that referenced this issue Jan 6, 2022
apply workaround from #100 (comment)
@Enmk
Copy link
Collaborator

Enmk commented Feb 2, 2022

Should be now fixed by #128
Also, we now have full support of Windows for both msvc (#131) and mingw (#137) builds

@Enmk Enmk closed this as completed Feb 2, 2022
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

No branches or pull requests

3 participants