diff options
author | Renato Filho <renato.filho@openbossa.org> | 2010-06-09 11:11:37 -0300 |
---|---|---|
committer | Hugo Parente Lima <hugo.pl@gmail.com> | 2012-03-09 19:10:04 -0300 |
commit | 3649c91f1bdad3ce7db3ff895ae40edf06fc232e (patch) | |
tree | d4f41966ff8e1ddc6e267b3c4ff3da75364b12e0 /abstractmetalang.h | |
parent | 96316113bcd6e60bc602def066cb03ec5ece436b (diff) |
Enable warning for arguments without name.
Reviewer: Luciano Wolf <luciano.wolf@openbossa.org>,
Marcelo Lira <marcelo.lira@openbossa.org>
Diffstat (limited to 'abstractmetalang.h')
-rw-r--r-- | abstractmetalang.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/abstractmetalang.h b/abstractmetalang.h index 6609eb936..ba72b35cb 100644 --- a/abstractmetalang.h +++ b/abstractmetalang.h @@ -687,6 +687,11 @@ public: AbstractMetaArgument *copy() const; + bool hasName() const + { + return !AbstractMetaVariable::name().isEmpty(); + } + private: // Just to force people to call argumentName() And indexedName(); QString name() const; @@ -694,6 +699,8 @@ private: QString m_expression; QString m_originalExpression; int m_argumentIndex; + + friend class AbstractMetaClass; }; @@ -1068,6 +1075,11 @@ public: bool hasSignatureModifications() const; FunctionModificationList modifications(const AbstractMetaClass* implementor = 0) const; + /** + * Return the argument name if there is a modification the renamed value will be returned + */ + QString argumentName(int index, bool create = true, const AbstractMetaClass *cl = 0) const; + // If this function stems from an interface, this returns the // interface that declares it. const AbstractMetaClass *interfaceClass() const |