summaryrefslogtreecommitdiff
path: root/src/argument.cpp
diff options
context:
space:
mode:
authorEmiel Bruijntjes <emiel.bruijntjes@copernica.com>2013-08-28 23:11:57 +0200
committerEmiel Bruijntjes <emiel.bruijntjes@copernica.com>2013-08-28 23:11:57 +0200
commit5ab6927a5fa17e73161d7126ca506e5e51ba0e55 (patch)
tree321186e3f01c09c5f739725da5a06abc31104b67 /src/argument.cpp
parentd69d5ca8f8f6a8c75099052f8541d7144385572c (diff)
added parameter handling, and return value handling
Diffstat (limited to 'src/argument.cpp')
-rw-r--r--src/argument.cpp14
1 files changed, 13 insertions, 1 deletions
diff --git a/src/argument.cpp b/src/argument.cpp
index 153da9c..fc9d720 100644
--- a/src/argument.cpp
+++ b/src/argument.cpp
@@ -28,8 +28,9 @@ Argument::Argument(const std::string &name, const std::string &classname, bool n
/**
* Constructor if the argument can be anything
+ * Note that only arrayType and callableType are supported type-hints
* @param name Name of the argument
- * @param type Type hint
+ * @param type Type hint (arrayType or callableType)
* @param ref Is this a pass-by-reference argument?
*/
Argument::Argument(const std::string &name, Type type, bool ref)
@@ -39,6 +40,17 @@ Argument::Argument(const std::string &name, Type type, bool ref)
}
/**
+ * Constructor if the argument can be anything
+ * @param name Name of the argument
+ * @param ref Is this a pass-by-reference argument?
+ */
+Argument::Argument(const std::string &name, bool ref)
+{
+ _refcount = new int[1];
+ _info = new ArgInfo(name, ref);
+}
+
+/**
* Clean up the object
*/
void Argument::cleanup()