From 52fe0c39457421e075959179ee6b64a20b96f0d9 Mon Sep 17 00:00:00 2001 From: Emiel Bruijntjes Date: Sun, 2 Mar 2014 11:33:53 +0100 Subject: types are not a C++11 class, introduced FixedValue class that can not change type, and implemented both Object and Array to make use of that type, implemented - but not yet tested - Base::value() method --- src/argument.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/argument.cpp') diff --git a/src/argument.cpp b/src/argument.cpp index e8e7c8a..080bf79 100644 --- a/src/argument.cpp +++ b/src/argument.cpp @@ -29,7 +29,7 @@ Argument::Argument(const char *name, Type type, bool required, bool byref) _info->name = name; _info->name_len = strlen(name); #if PHP_VERSION_ID >= 50400 - _info->type_hint = type == arrayType || type == callableType ? type : 0; + _info->type_hint = (unsigned char)(type == Type::Array || type == Type::Callable ? type : Type::Null); #endif _info->class_name = NULL; _info->class_name_len = 0; @@ -57,7 +57,7 @@ Argument::Argument(const char *name, const char *classname, bool nullable, bool _info->name = name; _info->name_len = strlen(name); #if PHP_VERSION_ID >= 50400 - _info->type_hint = objectType; + _info->type_hint = (unsigned char)Type::Object; #endif _info->class_name = classname; _info->class_name_len = strlen(classname); -- cgit v1.2.3