From 3ddc5c9e3777fff5c17f74902bb5ddc7cdaf1eb1 Mon Sep 17 00:00:00 2001 From: Toon Schoenmakers Date: Thu, 25 Sep 2014 11:04:09 +0200 Subject: Made Type::Null the default type on ByVal and ByRef as this will allow any type (aka no type hinting) --- include/byref.h | 8 ++++---- include/byval.h | 8 ++++---- include/type.h | 2 +- 3 files changed, 9 insertions(+), 9 deletions(-) (limited to 'include') diff --git a/include/byref.h b/include/byref.h index e828660..317c5c6 100644 --- a/include/byref.h +++ b/include/byref.h @@ -24,8 +24,8 @@ public: * @param type Argument type * @param required Is this argument required? */ - ByRef(const char *name, Type type, bool required = true) : Argument(name, type, required, true) {} - + ByRef(const char *name, Type type = Type::Null, bool required = true) : Argument(name, type, required, true) {} + /** * Constructor * @param name Name of the argument @@ -34,7 +34,7 @@ public: * @param required Is this argument required? */ ByRef(const char *name, const char *classname, bool nullable = false, bool required = true) : Argument(name, classname, nullable, required, true) {} - + /** * Copy constructor * @param argument @@ -46,7 +46,7 @@ public: * @param argument */ ByRef(ByRef &&argument) : Argument(argument) {} - + /** * Destructor */ diff --git a/include/byval.h b/include/byval.h index 40a458c..66f9b8f 100644 --- a/include/byval.h +++ b/include/byval.h @@ -24,8 +24,8 @@ public: * @param type Argument type * @param required Is this argument required? */ - ByVal(const char *name, Type type, bool required = true) : Argument(name, type, required, false) {} - + ByVal(const char *name, Type type = Type::Null, bool required = true) : Argument(name, type, required, false) {} + /** * Constructor * @param name Name of the argument @@ -34,7 +34,7 @@ public: * @param required Is this argument required? */ ByVal(const char *name, const char *classname, bool nullable = false, bool required = true) : Argument(name, classname, nullable, required, false) {} - + /** * Copy constructor * @param argument @@ -46,7 +46,7 @@ public: * @param argument */ ByVal(ByVal &&argument) : Argument(argument) {} - + /** * Destructor */ diff --git a/include/type.h b/include/type.h index bec0fd5..d248455 100644 --- a/include/type.h +++ b/include/type.h @@ -18,7 +18,7 @@ namespace Php { * The values are the same as the ones used internally in Zend */ enum class Type : unsigned char { - Null = 0, + Null = 0, // Null will allow any type Numeric = 1, Float = 2, Bool = 3, -- cgit v1.2.3