Open t2dk49580 opened 2 years ago
Looks like a duplicate of https://github.com/dtschump/CImg/issues/347
CIMG conflicts with httplib. If CIMG first #include, httplib will report an error, and if httplib first #include, CIMG will report an error. Please help solve it
After investigation, it appears httplib include resolv.h
which define macro _res
(l.162).
CImg uses _res
as a variable name which creates the conflict.
Defining _res
as a macro is really awful. Macros in a header file should be at least prefixed with something to avoid this kind of troubles.
I've renamed my variables _res
to _resu
as a workaround:
https://github.com/dtschump/CImg/commit/a01439210974d9f285e3c93750f26cf276f5ffb5
invalid pure specifier (only ‘= 0’ is allowed) before ‘<=’ token
line: 38682 38746 38813 38881