1) Added global static const std::string emptyString; object:
-> Replaces some static variables in functions which might be not threadsafe
-> Avoids constructor call (std::string::string(""))
-> Even functions that return an empty string in some branches can return by reference now.
Added to config.h to ensure that it is available everywhere
2) Added overloads for TestFixture::assertEquals for the most common use cases:
-> Moves conversion from const char[] to std::string into a function, reducing code duplication in binary.
- Changed behaviour of Token::function - is now also set for declarations
- Resolved TODO in testclass.cpp
- removed redundant code in Scope::findFunction - it is safe to call nextArgument() on functions without arguments
- Use Token::function in checkother.cpp
- Split up && when it is part of an rvalue reference declaration
- Added support into symbol database
- Current implementation sets Variable::isReference() to true also for rvalue references - they can probably be treated like normal references in many checks.
Changed behaviour of symbol database: Insert argument Variable of functions that are not implemented into SymbolDatabase::_variableList
- For each class/struct/union, a Type instance is added to SymbolDatabase::typeList.
- A scope is no longer created for declared but not defined types
Fixed name detection for classes when they are declared like this: "class ::Foo::Sub {..."
1. fix typos / misspellings
- Fix misspelling within comments, variable/function names, stdout messages
- changes the name of an error code: ```stlBoundries``` changed to ```stlBoundaries```. Alias old name (```stlBoundries```) to the new one.
2. fix gcc v3.4.6 32bit & 64bit warnings
- fixes gcc v3.4.6 warnings, except for those in tinyxml and "-Wmissing-declarations" makefile warnings
- in Preprocessor::handleIncludes(), replace a ```vector <bool>``` with ```stack<bool>``` (see ```vector<bool>``` warning below).
- this is the only ```vector<bool>``` in the codebase
- ```vector <bool>``` is actually a case of template specialization, and is not recommended, according to the following links:
http://stackoverflow.com/q/6461487http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2007/n2160.htmlhttp://stackoverflow.com/q/670308
- in the codebase before and after this change, testrunner SEGVs in a number of places on gcc v3.4.6, including ```Check::~Check()```, among others
- fc42fc95 fixes this particular runtime issue for DJGPP & __sun
1)The SymbolDatabase::findScope code is moved to the const-version. The non-const version is reimplemented as the combination with const_cast and static_cast.
2)Unrelated: change style of the declaration of some functions (the '*' is moved near the function name).