rename _flags to mFlags

This commit is contained in:
Daniel Marjamäki 2018-06-16 16:14:34 +02:00
parent 67b111f11e
commit 363f4ca939
4 changed files with 13 additions and 13 deletions

View File

@ -2633,7 +2633,7 @@ void SymbolDatabase::printVariable(const Variable *var, const char *indent) cons
var->isLocal() ? "Local" : var->isLocal() ? "Local" :
var->isThrow() ? "Throw" : var->isThrow() ? "Throw" :
"Unknown") << std::endl; "Unknown") << std::endl;
std::cout << indent << "_flags: " << std::endl; std::cout << indent << "mFlags: " << std::endl;
std::cout << indent << " isMutable: " << var->isMutable() << std::endl; std::cout << indent << " isMutable: " << var->isMutable() << std::endl;
std::cout << indent << " isStatic: " << var->isStatic() << std::endl; std::cout << indent << " isStatic: " << var->isStatic() << std::endl;
std::cout << indent << " isExtern: " << var->isExtern() << std::endl; std::cout << indent << " isExtern: " << var->isExtern() << std::endl;

View File

@ -199,7 +199,7 @@ class CPPCHECKLIB Variable {
* @return true if flag set or false in flag not set * @return true if flag set or false in flag not set
*/ */
bool getFlag(unsigned int flag_) const { bool getFlag(unsigned int flag_) const {
return ((_flags & flag_) != 0); return ((mFlags & flag_) != 0);
} }
/** /**
@ -208,7 +208,7 @@ class CPPCHECKLIB Variable {
* @param state_ new state of flag * @param state_ new state of flag
*/ */
void setFlag(unsigned int flag_, bool state_) { void setFlag(unsigned int flag_, bool state_) {
_flags = state_ ? _flags | flag_ : _flags & ~flag_; mFlags = state_ ? mFlags | flag_ : mFlags & ~flag_;
} }
/** /**
@ -227,7 +227,7 @@ public:
mTypeEndToken(end_), mTypeEndToken(end_),
mIndex(index_), mIndex(index_),
mAccess(access_), mAccess(access_),
_flags(0), mFlags(0),
mConstness(0), mConstness(0),
_type(type_), _type(type_),
_scope(scope_) { _scope(scope_) {
@ -631,7 +631,7 @@ private:
AccessControl mAccess; // public/protected/private AccessControl mAccess; // public/protected/private
/** @brief flags */ /** @brief flags */
unsigned int _flags; unsigned int mFlags;
/** @brief constness (same encoding as ValueType::constness) */ /** @brief constness (same encoding as ValueType::constness) */
unsigned int mConstness; unsigned int mConstness;

View File

@ -48,7 +48,7 @@ Token::Token(TokensFrontBack *tokensFrontBack) :
_col(0), _col(0),
_progressValue(0), _progressValue(0),
_tokType(eNone), _tokType(eNone),
_flags(0), mFlags(0),
_bits(0), _bits(0),
_astOperand1(nullptr), _astOperand1(nullptr),
_astOperand2(nullptr), _astOperand2(nullptr),
@ -248,7 +248,7 @@ void Token::swapWithNext()
if (_next) { if (_next) {
std::swap(_str, _next->_str); std::swap(_str, _next->_str);
std::swap(_tokType, _next->_tokType); std::swap(_tokType, _next->_tokType);
std::swap(_flags, _next->_flags); std::swap(mFlags, _next->mFlags);
std::swap(_varId, _next->_varId); std::swap(_varId, _next->_varId);
std::swap(_fileIndex, _next->_fileIndex); std::swap(_fileIndex, _next->_fileIndex);
std::swap(_linenr, _next->_linenr); std::swap(_linenr, _next->_linenr);
@ -270,7 +270,7 @@ void Token::takeData(Token *fromToken)
{ {
_str = fromToken->_str; _str = fromToken->_str;
tokType(fromToken->_tokType); tokType(fromToken->_tokType);
_flags = fromToken->_flags; mFlags = fromToken->mFlags;
_varId = fromToken->_varId; _varId = fromToken->_varId;
_fileIndex = fromToken->_fileIndex; _fileIndex = fromToken->_fileIndex;
_linenr = fromToken->_linenr; _linenr = fromToken->_linenr;

View File

@ -312,10 +312,10 @@ public:
bool isUnaryPreOp() const; bool isUnaryPreOp() const;
unsigned int flags() const { unsigned int flags() const {
return _flags; return mFlags;
} }
void flags(const unsigned int flags_) { void flags(const unsigned int flags_) {
_flags = flags_; mFlags = flags_;
} }
bool isUnsigned() const { bool isUnsigned() const {
return getFlag(fIsUnsigned); return getFlag(fIsUnsigned);
@ -958,7 +958,7 @@ private:
fIsAttributeNodiscard = (1 << 23), // __attribute__ ((warn_unused_result)), [[nodiscard]] fIsAttributeNodiscard = (1 << 23), // __attribute__ ((warn_unused_result)), [[nodiscard]]
}; };
unsigned int _flags; unsigned int mFlags;
/** /**
* Get specified flag state. * Get specified flag state.
@ -966,7 +966,7 @@ private:
* @return true if flag set or false in flag not set * @return true if flag set or false in flag not set
*/ */
bool getFlag(unsigned int flag_) const { bool getFlag(unsigned int flag_) const {
return ((_flags & flag_) != 0); return ((mFlags & flag_) != 0);
} }
/** /**
@ -975,7 +975,7 @@ private:
* @param state_ new state of flag * @param state_ new state of flag
*/ */
void setFlag(unsigned int flag_, bool state_) { void setFlag(unsigned int flag_, bool state_) {
_flags = state_ ? _flags | flag_ : _flags & ~flag_; mFlags = state_ ? mFlags | flag_ : mFlags & ~flag_;
} }
/** Updates internal property cache like _isName or _isBoolean. /** Updates internal property cache like _isName or _isBoolean.