summaryrefslogtreecommitdiffstats
path: root/src/arguments.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/arguments.h')
-rw-r--r--src/arguments.h83
1 files changed, 29 insertions, 54 deletions
diff --git a/src/arguments.h b/src/arguments.h
index 7ef9642..3464def 100644
--- a/src/arguments.h
+++ b/src/arguments.h
@@ -16,45 +16,15 @@
#ifndef ARGUMENTS_H
#define ARGUMENTS_H
-#include <qlist.h>
+#include <vector>
#include <qcstring.h>
-class StorageIntf;
-
/*! \brief This class contains the information about the argument of a
* function or template
*
*/
struct Argument
{
- /*! Construct a new argument. */
- Argument() {}
- /*! Copy an argument (does a deep copy of all strings). */
- Argument(const Argument &a)
- {
- attrib=a.attrib;
- type=a.type;
- name=a.name;
- array=a.array;
- defval=a.defval;
- docs=a.docs;
- typeConstraint=a.typeConstraint;
- }
- /*! Assignment of an argument (does a deep copy of all strings). */
- Argument &operator=(const Argument &a)
- {
- if (this!=&a)
- {
- attrib=a.attrib;
- type=a.type;
- name=a.name;
- array=a.array;
- defval=a.defval;
- docs=a.docs;
- typeConstraint=a.typeConstraint;
- }
- return *this;
- }
/*! return TRUE if this argument is documentation and the argument has a
* non empty name.
*/
@@ -86,37 +56,42 @@ enum RefQualifierType
* put after the argument list, such as whether the member is const,
* volatile or pure virtual.
*/
-class ArgumentList : public QList<Argument>
+class ArgumentList : public std::vector<Argument>
{
public:
- /*! Creates an empty argument list */
- ArgumentList() : QList<Argument>(),
- constSpecifier(FALSE),
- volatileSpecifier(FALSE),
- pureSpecifier(FALSE),
- isDeleted(FALSE),
- refQualifier(RefQualifierNone)
- { setAutoDelete(TRUE); }
- /*! Destroys the argument list */
- ~ArgumentList() {}
- /*! Makes a deep copy of this object */
- ArgumentList *deepCopy() const;
/*! Does any argument of this list have documentation? */
bool hasDocumentation() const;
- /*! Does the member modify the state of the class? default: FALSE. */
- bool constSpecifier;
- /*! Is the member volatile? default: FALSE. */
- bool volatileSpecifier;
- /*! Is this a pure virtual member? default: FALSE */
- bool pureSpecifier;
+ /*! Does this list have zero or more parameters */
+ bool hasParameters() const
+ {
+ return !empty() || noParameters;
+ }
+ void reset()
+ {
+ clear();
+ constSpecifier = FALSE;
+ volatileSpecifier = FALSE;
+ pureSpecifier = FALSE;
+ trailingReturnType.resize(0);
+ isDeleted = FALSE;
+ refQualifier = RefQualifierNone;
+ noParameters = FALSE;
+ }
+
+ /*! Does the member modify the state of the class? */
+ bool constSpecifier = FALSE;
+ /*! Is the member volatile? */
+ bool volatileSpecifier = FALSE;
+ /*! Is this a pure virtual member? */
+ bool pureSpecifier = FALSE;
/*! C++11 style Trailing return type? */
QCString trailingReturnType;
/*! method with =delete */
- bool isDeleted;
+ bool isDeleted = FALSE;
/*! C++11 ref qualifier */
- RefQualifierType refQualifier;
+ RefQualifierType refQualifier = RefQualifierNone;
+ /*! is it an explicit empty list */
+ bool noParameters = FALSE;
};
-typedef QListIterator<Argument> ArgumentListIterator;
-
#endif