astyle formatting
This commit is contained in:
parent
465555e39d
commit
139414bd5c
|
@ -43,14 +43,15 @@ void Check::reportError(const ErrorLogger::ErrorMessage &errmsg)
|
|||
std::cout << errmsg.toXML(true, 1) << std::endl;
|
||||
}
|
||||
|
||||
std::list<Check *> &Check::instances() {
|
||||
std::list<Check *> &Check::instances()
|
||||
{
|
||||
#ifdef __SVR4
|
||||
// Under Solaris, destructors are called in wrong order which causes a segmentation fault.
|
||||
// This fix ensures pointer remains valid and reachable until program terminates.
|
||||
static std::list<Check *> *_instances= new std::list<Check *>;
|
||||
return *_instances;
|
||||
// Under Solaris, destructors are called in wrong order which causes a segmentation fault.
|
||||
// This fix ensures pointer remains valid and reachable until program terminates.
|
||||
static std::list<Check *> *_instances= new std::list<Check *>;
|
||||
return *_instances;
|
||||
#else
|
||||
static std::list<Check *> _instances;
|
||||
return _instances;
|
||||
static std::list<Check *> _instances;
|
||||
return _instances;
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
|
|
@ -53,7 +53,7 @@ public:
|
|||
}
|
||||
|
||||
/** List of registered check classes. This is used by Cppcheck to run checks and generate documentation */
|
||||
static std::list<Check *> &instances();
|
||||
static std::list<Check *> &instances();
|
||||
|
||||
/** run checks, the token list is not simplified */
|
||||
virtual void runChecks(const Tokenizer *, const Settings *, ErrorLogger *) {
|
||||
|
|
Loading…
Reference in New Issue