]> granicus.if.org Git - php/commitdiff
- MFB: Added arginfo
authorFelipe Pena <felipe@php.net>
Mon, 14 Jul 2008 18:09:11 +0000 (18:09 +0000)
committerFelipe Pena <felipe@php.net>
Mon, 14 Jul 2008 18:09:11 +0000 (18:09 +0000)
ext/com_dotnet/com_extension.c
ext/readline/readline.c

index f10b8e04e21ed88a4b544feb3df288dc8fc6553a..cc5b1c1604b207c9bce9b2a5f49e2b50c87e5f7e 100644 (file)
@@ -39,40 +39,227 @@ zend_class_entry
        *php_com_exception_class_entry,
        *php_com_saproxy_class_entry;
 
+/* {{{ arginfo */
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_variant_set, 0, 0, 2)
+       ZEND_ARG_INFO(0, variant)
+       ZEND_ARG_INFO(0, value)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_variant_add, 0, 0, 2)
+       ZEND_ARG_INFO(0, left)
+       ZEND_ARG_INFO(0, right)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_variant_cat, 0, 0, 2)
+       ZEND_ARG_INFO(0, left)
+       ZEND_ARG_INFO(0, right)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_variant_sub, 0, 0, 2)
+       ZEND_ARG_INFO(0, left)
+       ZEND_ARG_INFO(0, right)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_variant_mul, 0, 0, 2)
+       ZEND_ARG_INFO(0, left)
+       ZEND_ARG_INFO(0, right)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_variant_and, 0, 0, 2)
+       ZEND_ARG_INFO(0, left)
+       ZEND_ARG_INFO(0, right)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_variant_div, 0, 0, 2)
+       ZEND_ARG_INFO(0, left)
+       ZEND_ARG_INFO(0, right)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_variant_eqv, 0, 0, 2)
+       ZEND_ARG_INFO(0, left)
+       ZEND_ARG_INFO(0, right)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_variant_idiv, 0, 0, 2)
+       ZEND_ARG_INFO(0, left)
+       ZEND_ARG_INFO(0, right)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_variant_imp, 0, 0, 2)
+       ZEND_ARG_INFO(0, left)
+       ZEND_ARG_INFO(0, right)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_variant_mod, 0, 0, 2)
+       ZEND_ARG_INFO(0, left)
+       ZEND_ARG_INFO(0, right)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_variant_or, 0, 0, 2)
+       ZEND_ARG_INFO(0, left)
+       ZEND_ARG_INFO(0, right)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_variant_pow, 0, 0, 2)
+       ZEND_ARG_INFO(0, left)
+       ZEND_ARG_INFO(0, right)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_variant_xor, 0, 0, 2)
+       ZEND_ARG_INFO(0, left)
+       ZEND_ARG_INFO(0, right)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_variant_abs, 0, 0, 1)
+       ZEND_ARG_INFO(0, left)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_variant_fix, 0, 0, 1)
+       ZEND_ARG_INFO(0, left)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_variant_int, 0, 0, 1)
+       ZEND_ARG_INFO(0, left)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_variant_neg, 0, 0, 1)
+       ZEND_ARG_INFO(0, left)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_variant_not, 0, 0, 1)
+       ZEND_ARG_INFO(0, left)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_variant_round, 0, 0, 2)
+       ZEND_ARG_INFO(0, left)
+       ZEND_ARG_INFO(0, decimals)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_variant_cmp, 0, 0, 2)
+       ZEND_ARG_INFO(0, left)
+       ZEND_ARG_INFO(0, right)
+       ZEND_ARG_INFO(0, lcid)
+       ZEND_ARG_INFO(0, flags)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_variant_date_to_timestamp, 0, 0, 1)
+       ZEND_ARG_INFO(0, variant)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_variant_date_from_timestamp, 0, 0, 1)
+       ZEND_ARG_INFO(0, timestamp)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_variant_get_type, 0, 0, 1)
+       ZEND_ARG_INFO(0, variant)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_variant_set_type, 0, 0, 2)
+       ZEND_ARG_INFO(0, variant)
+       ZEND_ARG_INFO(0, type)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_variant_cast, 0, 0, 2)
+       ZEND_ARG_INFO(0, variant)
+       ZEND_ARG_INFO(0, type)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_com_get_active_object, 0, 0, 1)
+       ZEND_ARG_INFO(0, progid)
+       ZEND_ARG_INFO(0, code_page)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO(arginfo_com_create_guid, 0)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_com_event_sink, 0, 0, 2)
+       ZEND_ARG_INFO(0, comobject)
+       ZEND_ARG_INFO(0, sinkobject)
+       ZEND_ARG_INFO(0, sinkinterface)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_com_print_typeinfo, 0, 0, 1)
+       ZEND_ARG_INFO(0, comobject)
+       ZEND_ARG_INFO(0, dispinterface)
+       ZEND_ARG_INFO(0, wantsink)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_com_message_pump, 0, 0, 0)
+       ZEND_ARG_INFO(0, timeoutms)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_com_load_typelib, 0, 0, 1)
+       ZEND_ARG_INFO(0, typelib_name)
+       ZEND_ARG_INFO(0, case_insensitive)
+ZEND_END_ARG_INFO()
+/* }}} */
+
 const zend_function_entry com_dotnet_functions[] = {
-       PHP_FE(variant_set, NULL)
-       PHP_FE(variant_add, NULL)
-       PHP_FE(variant_cat, NULL)
-       PHP_FE(variant_sub, NULL)
-       PHP_FE(variant_mul, NULL)
-       PHP_FE(variant_and, NULL)
-       PHP_FE(variant_div, NULL)
-       PHP_FE(variant_eqv, NULL)
-       PHP_FE(variant_idiv, NULL)
-       PHP_FE(variant_imp, NULL)
-       PHP_FE(variant_mod, NULL)
-       PHP_FE(variant_or, NULL)
-       PHP_FE(variant_pow, NULL)
-       PHP_FE(variant_xor, NULL)
-       PHP_FE(variant_abs, NULL)
-       PHP_FE(variant_fix, NULL)
-       PHP_FE(variant_int, NULL)
-       PHP_FE(variant_neg, NULL)
-       PHP_FE(variant_not, NULL)
-       PHP_FE(variant_round, NULL)
-       PHP_FE(variant_cmp, NULL)
-       PHP_FE(variant_date_to_timestamp, NULL)
-       PHP_FE(variant_date_from_timestamp, NULL)
-       PHP_FE(variant_get_type, NULL)
-       PHP_FE(variant_set_type, NULL)
-       PHP_FE(variant_cast, NULL)
+       PHP_FE(variant_set, arginfo_variant_set)
+       PHP_FE(variant_add, arginfo_variant_add)
+       PHP_FE(variant_cat, arginfo_variant_cat)
+       PHP_FE(variant_sub, arginfo_variant_sub)
+       PHP_FE(variant_mul, arginfo_variant_mul)
+       PHP_FE(variant_and, arginfo_variant_and)
+       PHP_FE(variant_div, arginfo_variant_div)
+       PHP_FE(variant_eqv, arginfo_variant_eqv)
+       PHP_FE(variant_idiv, arginfo_variant_idiv)
+       PHP_FE(variant_imp, arginfo_variant_imp)
+       PHP_FE(variant_mod, arginfo_variant_mod)
+       PHP_FE(variant_or, arginfo_variant_or)
+       PHP_FE(variant_pow, arginfo_variant_pow)
+       PHP_FE(variant_xor, arginfo_variant_xor)
+       PHP_FE(variant_abs, arginfo_variant_abs)
+       PHP_FE(variant_fix, arginfo_variant_fix)
+       PHP_FE(variant_int, arginfo_variant_int)
+       PHP_FE(variant_neg, arginfo_variant_neg)
+       PHP_FE(variant_not, arginfo_variant_not)
+       PHP_FE(variant_round, arginfo_variant_round)
+       PHP_FE(variant_cmp, arginfo_variant_cmp)
+       PHP_FE(variant_date_to_timestamp, arginfo_variant_date_to_timestamp)
+       PHP_FE(variant_date_from_timestamp, arginfo_variant_date_from_timestamp)
+       PHP_FE(variant_get_type, arginfo_variant_get_type)
+       PHP_FE(variant_set_type, arginfo_variant_set_type)
+       PHP_FE(variant_cast, arginfo_variant_cast)
        /* com_com.c */
-       PHP_FE(com_create_guid, NULL)
-       PHP_FE(com_event_sink, NULL)
-       PHP_FE(com_print_typeinfo, NULL)
-       PHP_FE(com_message_pump, NULL)
-       PHP_FE(com_load_typelib, NULL)
-       PHP_FE(com_get_active_object, NULL)
+       PHP_FE(com_create_guid, arginfo_com_create_guid)
+       PHP_FE(com_event_sink, arginfo_com_event_sink)
+       PHP_FE(com_print_typeinfo, arginfo_com_print_typeinfo)
+       PHP_FE(com_message_pump, arginfo_com_message_pump)
+       PHP_FE(com_load_typelib, arginfo_com_load_typelib)
+       PHP_FE(com_get_active_object, arginfo_com_get_active_object)
        { NULL, NULL, NULL }
 };
 
index b1b1812569e6bc6216dcba331777c688e185bc16..ba684389787f73c70930f7de49748ac98b111284 100644 (file)
@@ -67,25 +67,92 @@ PHP_MINIT_FUNCTION(readline);
 PHP_RSHUTDOWN_FUNCTION(readline);
 
 /* }}} */
-/* {{{ module stuff */
 
+/* {{{ arginfo */
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_readline, 0, 0, 0)
+       ZEND_ARG_INFO(0, prompt)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_readline_info, 0, 0, 0)
+       ZEND_ARG_INFO(0, varname)
+       ZEND_ARG_INFO(0, newvalue)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_readline_add_history, 0, 0, 1)
+       ZEND_ARG_INFO(0, prompt)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO(arginfo_readline_clear_history, 0)
+ZEND_END_ARG_INFO()
+
+#ifndef HAVE_LIBEDIT
+static
+ZEND_BEGIN_ARG_INFO(arginfo_readline_list_history, 0)
+ZEND_END_ARG_INFO()
+#endif
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_readline_read_history, 0, 0, 0)
+       ZEND_ARG_INFO(0, filename)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_readline_write_history, 0, 0, 0)
+       ZEND_ARG_INFO(0, filename)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_readline_completion_function, 0, 0, 1)
+       ZEND_ARG_INFO(0, funcname)
+ZEND_END_ARG_INFO()
+
+#if HAVE_RL_CALLBACK_READ_CHAR
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_readline_callback_handler_install, 0, 0, 2)
+       ZEND_ARG_INFO(0, prompt)
+       ZEND_ARG_INFO(0, callback)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO(arginfo_readline_callback_read_char, 0)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO(arginfo_readline_callback_handler_remove, 0)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO(arginfo_readline_redisplay, 0)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO(arginfo_readline_on_new_line, 0)
+ZEND_END_ARG_INFO()
+#endif
+/* }}} */
+
+/* {{{ module stuff */
 static const zend_function_entry php_readline_functions[] = {
-       PHP_FE(readline,                                NULL)
-       PHP_FE(readline_info,               NULL)
-       PHP_FE(readline_add_history,            NULL)
-       PHP_FE(readline_clear_history,          NULL)
+       PHP_FE(readline,                                arginfo_readline)
+       PHP_FE(readline_info,               arginfo_readline_info)
+       PHP_FE(readline_add_history,            arginfo_readline_add_history)
+       PHP_FE(readline_clear_history,          arginfo_readline_clear_history)
 #ifndef HAVE_LIBEDIT
-       PHP_FE(readline_list_history,           NULL)
+       PHP_FE(readline_list_history,           arginfo_readline_list_history)
 #endif
-       PHP_FE(readline_read_history,           NULL)
-       PHP_FE(readline_write_history,          NULL)
-       PHP_FE(readline_completion_function,NULL)
+       PHP_FE(readline_read_history,           arginfo_readline_read_history)
+       PHP_FE(readline_write_history,          arginfo_readline_write_history)
+       PHP_FE(readline_completion_function,arginfo_readline_completion_function)
 #if HAVE_RL_CALLBACK_READ_CHAR
-       PHP_FE(readline_callback_handler_install, NULL)
-       PHP_FE(readline_callback_read_char,                     NULL)
-       PHP_FE(readline_callback_handler_remove,        NULL)
-       PHP_FE(readline_redisplay, NULL)
-       PHP_FE(readline_on_new_line, NULL)
+       PHP_FE(readline_callback_handler_install, arginfo_readline_callback_handler_install)
+       PHP_FE(readline_callback_read_char,                     arginfo_readline_callback_read_char)
+       PHP_FE(readline_callback_handler_remove,        arginfo_readline_callback_handler_remove)
+       PHP_FE(readline_redisplay, arginfo_readline_redisplay)
+       PHP_FE(readline_on_new_line, arginfo_readline_on_new_line)
 #endif
        {NULL, NULL, NULL}
 };