Remove NORET_ATTR.
--HG-- branch : develop
This commit is contained in:
parent
5df36147d3
commit
2107a2205a
|
@ -295,7 +295,7 @@ VCommandLinePtr VCommandLine::Get(const QCoreApplication& app)
|
||||||
}
|
}
|
||||||
|
|
||||||
//------------------------------------------------------------------------------------------------------
|
//------------------------------------------------------------------------------------------------------
|
||||||
NORET_ATTR void VCommandLine::Error(const QString &text) const
|
Q_NORETURN void VCommandLine::Error(const QString &text) const
|
||||||
{
|
{
|
||||||
vStdErr() << text << "\n";
|
vStdErr() << text << "\n";
|
||||||
const_cast<VCommandLine*>(this)->parser.showHelp(FAILED_HELP_SHOWN_STATUS);
|
const_cast<VCommandLine*>(this)->parser.showHelp(FAILED_HELP_SHOWN_STATUS);
|
||||||
|
|
|
@ -18,9 +18,6 @@ constexpr auto FAILED_TO_GEN_LAYOUT_STATUS = 253;
|
||||||
constexpr auto FAILED_HELP_SHOWN_STATUS = 250;
|
constexpr auto FAILED_HELP_SHOWN_STATUS = 250;
|
||||||
constexpr auto FAILED_GEN_BASE_STATUS = 240;
|
constexpr auto FAILED_GEN_BASE_STATUS = 240;
|
||||||
|
|
||||||
#define NORET_ATTR Q_NORETURN
|
|
||||||
|
|
||||||
|
|
||||||
//---------------------------------------------------------------------------------------------------------------------
|
//---------------------------------------------------------------------------------------------------------------------
|
||||||
inline QTextStream& vStdErr()
|
inline QTextStream& vStdErr()
|
||||||
{
|
{
|
||||||
|
@ -29,7 +26,7 @@ inline QTextStream& vStdErr()
|
||||||
}
|
}
|
||||||
|
|
||||||
//---------------------------------------------------------------------------------------------------------------------
|
//---------------------------------------------------------------------------------------------------------------------
|
||||||
NORET_ATTR inline void AppAbort(const QString& text = QString(), int code = GENERAL_ERROR_STATUS)
|
Q_NORETURN inline void AppAbort(const QString& text = QString(), int code = GENERAL_ERROR_STATUS)
|
||||||
{
|
{
|
||||||
//well ..std::runtime_error was leading to zombies in memory and a lot of dumping all the time ...better to do just exit
|
//well ..std::runtime_error was leading to zombies in memory and a lot of dumping all the time ...better to do just exit
|
||||||
//possibly compiler do not have -fexceptions set
|
//possibly compiler do not have -fexceptions set
|
||||||
|
@ -71,7 +68,7 @@ protected:
|
||||||
Cases OptGroup() const;
|
Cases OptGroup() const;
|
||||||
|
|
||||||
//@brief convinient shortcut to show error and help and exit
|
//@brief convinient shortcut to show error and help and exit
|
||||||
NORET_ATTR void Error(const QString& text) const;
|
Q_NORETURN void Error(const QString& text) const;
|
||||||
|
|
||||||
//@brief: called in destructor of application, so instance destroyed and new maybe created (never happen scenario though)
|
//@brief: called in destructor of application, so instance destroyed and new maybe created (never happen scenario though)
|
||||||
static void Reset();
|
static void Reset();
|
||||||
|
|
Loading…
Reference in New Issue
Block a user