#include <iostream>
using namespace std;
void may() noexcept(throw std::logic_error())
{
cout << "nnn";
}
int main() {
return 0;
}
I2luY2x1ZGUgPGlvc3RyZWFtPgp1c2luZyBuYW1lc3BhY2Ugc3RkOwoKdm9pZCBtYXkoKSBub2V4Y2VwdCh0aHJvdyBzdGQ6OmxvZ2ljX2Vycm9yKCkpCnsKCWNvdXQgPDwgIm5ubiI7Cn0KCmludCBtYWluKCkgewoKCXJldHVybiAwOwp9
prog.cpp:4:44: error: no matching function for call to ‘std::logic_error::logic_error()’
void may() noexcept(throw std::logic_error())
^
In file included from /usr/include/c++/6/system_error:41:0,
from /usr/include/c++/6/bits/ios_base.h:46,
from /usr/include/c++/6/ios:42,
from /usr/include/c++/6/ostream:38,
from /usr/include/c++/6/iostream:39,
from prog.cpp:1:
/usr/include/c++/6/stdexcept:128:5: note: candidate: std::logic_error::logic_error(const std::logic_error&)
logic_error(const logic_error&) _GLIBCXX_USE_NOEXCEPT;
^~~~~~~~~~~
/usr/include/c++/6/stdexcept:128:5: note: candidate expects 1 argument, 0 provided
/usr/include/c++/6/stdexcept:124:5: note: candidate: std::logic_error::logic_error(const char*)
logic_error(const char*) _GLIBCXX_TXN_SAFE;
^~~~~~~~~~~
/usr/include/c++/6/stdexcept:124:5: note: candidate expects 1 argument, 0 provided
/usr/include/c++/6/stdexcept:120:5: note: candidate: std::logic_error::logic_error(const string&)
logic_error(const string& __arg) _GLIBCXX_TXN_SAFE;
^~~~~~~~~~~
/usr/include/c++/6/stdexcept:120:5: note: candidate expects 1 argument, 0 provided