Comments (14)
Hi @antonlukyanov ,
can you try replacing it with noexcept?
from curlcpp.
@JosephP91, replacing NOEXCEPT to noexcept solved the problem, thanks. However, there are many places in headers where NOEXCEPT is used and everything compiles fine except for curl_header.h.
from curlcpp.
@antonlukyanov yes, I noticed this thing now. It's very strange. @qqiangwu how is this possible? In curl_header.h and curl_header.cpp, if I replace NOEXCEPT with noexcept, everything compiles. If I use NOEXCEPT it does not compile.
from curlcpp.
@antonlukyanov What's your compiler? gcc or mingw?
from curlcpp.
@qqiangwu I think MinGW. It is written in the first comment.
from curlcpp.
@qqiangwu, here is more precise information about used compiler:
$ g++ --version
g++.exe (i686-posix-dwarf-rev0, Built by MinGW-W64 project) 4.9.1
from curlcpp.
@JosephP91 I forgot to add #include "curl_config.h"
to curl_header.h
, so the macro NOEXCEPT
cannot be found and be parsed as a normal symbol.
from curlcpp.
@qqiangwu Oh, ok! I added the include. Thank you!
from curlcpp.
Solved
from curlcpp.
@JosephP91 BTW, destructors are by default noexcept, so the NOEXCEPT in ~curl_header() NOEXCEPT;
is redundant. :)
from curlcpp.
@qqiangwu So I could remove the NOEXCEPT from every destructor declaration. Right?
from curlcpp.
@JosephP91 Yeah! See also http://en.cppreference.com/w/cpp/language/noexcept_spec
from curlcpp.
It's always good to learn something! Thank you!
from curlcpp.
I still see this error when I compile with curl...
c:/.../curlcpp/include/curl_exception.h:64:25: error: expected ';' at end of member declaration
~curl_exception() NOEXCEPT;
^
In file included from c:/.../curlcpp/include/curl_easy.h:33:0,
c:/.../curlcpp/include/curl_config.h:32:22: error: 'noexcept' does not name a type
#define NOEXCEPT noexcept
etc.
I'm using the recent package of curlcpp and my gcc compiler version is even newer:
$ gcc --version
gcc.exe (i686-posix-dwarf-rev1, Built by MinGW-W64 project) 4.9.2
Any suggestions how to fix this compilation error? I don't want (and don't think I should be) to remove NOEXCEPT from curlcpp package as it compiles just fine and I was able to create the library.
from curlcpp.
Related Issues (20)
- warnings when building
- NOEXCEPT
- Release:1.2 Cmake fails. HOT 15
- compile warning: invalid use of incomplete type HOT 2
- curl_easy_exception doesn't set any message into std::exception HOT 1
- Build of 1.4 fail with mingw32 in win10 and curl 7.74.0 HOT 12
- Can't link on windows HOT 3
- Singleton initializer issue HOT 1
- replece curlcpp-master/include to curlcpp-master/include/curlcpp
- Can't link with a project with Dynamic CRT (VS2019)
- initialising order warnings HOT 1
- Is a new tag/release coming soon? HOT 1
- build fail with curl 7.83.0 HOT 2
- Static build? HOT 6
- Deprecation warnings with latest curl version
- How to get response content string when using curl_multi HOT 1
- Version inside CMake looks out of date HOT 1
- suggestion libev
- Titles in README.md mismatch
- BUILD_SHARED_LIBS non-standard usage.
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from curlcpp.