mirror of
https://github.com/php/php-src.git
synced 2025-01-25 13:14:22 +08:00
Properly declare methods
While declaring methods with `PHP_FALIAS` kind of works, it is semantically confusing, and also doesn't allow to specify access flags.
This commit is contained in:
parent
6e9dd13d63
commit
adcc35916a
@ -538,59 +538,59 @@ const zend_function_entry mysqli_functions[] = {
|
||||
* Every user visible function must have an entry in mysqli_functions[].
|
||||
*/
|
||||
const zend_function_entry mysqli_link_methods[] = {
|
||||
PHP_FALIAS(autocommit, mysqli_autocommit, arginfo_class_mysqli_autocommit)
|
||||
PHP_FALIAS(begin_transaction, mysqli_begin_transaction, arginfo_class_mysqli_begin_transaction)
|
||||
PHP_FALIAS(change_user,mysqli_change_user, arginfo_class_mysqli_change_user)
|
||||
PHP_FALIAS(character_set_name, mysqli_character_set_name, arginfo_mysqli_no_params)
|
||||
PHP_FALIAS(close, mysqli_close, arginfo_mysqli_no_params)
|
||||
PHP_FALIAS(commit, mysqli_commit, arginfo_class_mysqli_commit)
|
||||
PHP_FALIAS(connect, mysqli_connect, arginfo_mysqli_connect)
|
||||
PHP_FALIAS(dump_debug_info, mysqli_dump_debug_info, arginfo_mysqli_no_params)
|
||||
PHP_FALIAS(debug, mysqli_debug, arginfo_mysqli_debug)
|
||||
PHP_ME_MAPPING(autocommit, mysqli_autocommit, arginfo_class_mysqli_autocommit, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(begin_transaction, mysqli_begin_transaction, arginfo_class_mysqli_begin_transaction, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(change_user,mysqli_change_user, arginfo_class_mysqli_change_user, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(character_set_name, mysqli_character_set_name, arginfo_mysqli_no_params, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(close, mysqli_close, arginfo_mysqli_no_params, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(commit, mysqli_commit, arginfo_class_mysqli_commit, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(connect, mysqli_connect, arginfo_mysqli_connect, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(dump_debug_info, mysqli_dump_debug_info, arginfo_mysqli_no_params, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(debug, mysqli_debug, arginfo_mysqli_debug, ZEND_ACC_PUBLIC)
|
||||
#ifdef HAVE_MYSQLI_GET_CHARSET
|
||||
PHP_FALIAS(get_charset, mysqli_get_charset, arginfo_mysqli_no_params)
|
||||
PHP_ME_MAPPING(get_charset, mysqli_get_charset, arginfo_mysqli_no_params, ZEND_ACC_PUBLIC)
|
||||
#endif
|
||||
PHP_FALIAS(get_client_info, mysqli_get_client_info, arginfo_mysqli_no_params)
|
||||
PHP_ME_MAPPING(get_client_info, mysqli_get_client_info, arginfo_mysqli_no_params, ZEND_ACC_PUBLIC)
|
||||
#if defined(MYSQLI_USE_MYSQLND)
|
||||
PHP_FALIAS(get_connection_stats, mysqli_get_connection_stats, arginfo_mysqli_no_params)
|
||||
PHP_ME_MAPPING(get_connection_stats, mysqli_get_connection_stats, arginfo_mysqli_no_params, ZEND_ACC_PUBLIC)
|
||||
#endif
|
||||
PHP_FALIAS(get_server_info, mysqli_get_server_info, arginfo_mysqli_no_params)
|
||||
PHP_FALIAS(get_warnings, mysqli_get_warnings, arginfo_mysqli_no_params)
|
||||
PHP_FALIAS(init,mysqli_init_method, arginfo_mysqli_no_params)
|
||||
PHP_FALIAS(kill,mysqli_kill, arginfo_class_mysqli_kill)
|
||||
PHP_FALIAS(multi_query, mysqli_multi_query, arginfo_class_mysqli_multi_query)
|
||||
PHP_FALIAS(__construct, mysqli_link_construct, arginfo_mysqli_connect)
|
||||
PHP_FALIAS(more_results, mysqli_more_results, arginfo_mysqli_no_params)
|
||||
PHP_FALIAS(next_result, mysqli_next_result, arginfo_mysqli_no_params)
|
||||
PHP_FALIAS(options, mysqli_options, arginfo_class_mysqli_options)
|
||||
PHP_FALIAS(ping, mysqli_ping, arginfo_mysqli_no_params)
|
||||
PHP_ME_MAPPING(get_server_info, mysqli_get_server_info, arginfo_mysqli_no_params, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(get_warnings, mysqli_get_warnings, arginfo_mysqli_no_params, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(init,mysqli_init_method, arginfo_mysqli_no_params, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(kill,mysqli_kill, arginfo_class_mysqli_kill, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(multi_query, mysqli_multi_query, arginfo_class_mysqli_multi_query, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(__construct, mysqli_link_construct, arginfo_mysqli_connect, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(more_results, mysqli_more_results, arginfo_mysqli_no_params, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(next_result, mysqli_next_result, arginfo_mysqli_no_params, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(options, mysqli_options, arginfo_class_mysqli_options, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(ping, mysqli_ping, arginfo_mysqli_no_params, ZEND_ACC_PUBLIC)
|
||||
#if defined(MYSQLI_USE_MYSQLND)
|
||||
ZEND_FENTRY(poll, ZEND_FN(mysqli_poll), arginfo_mysqli_poll, ZEND_ACC_PUBLIC | ZEND_ACC_STATIC)
|
||||
PHP_ME_MAPPING(poll, mysqli_poll, arginfo_mysqli_poll, ZEND_ACC_PUBLIC | ZEND_ACC_STATIC)
|
||||
#endif
|
||||
PHP_FALIAS(prepare, mysqli_prepare, arginfo_class_mysqli_prepare)
|
||||
PHP_FALIAS(query, mysqli_query, arginfo_class_mysqli_query)
|
||||
PHP_FALIAS(real_connect, mysqli_real_connect, arginfo_class_mysqli_real_connect)
|
||||
PHP_FALIAS(real_escape_string, mysqli_real_escape_string, arginfo_class_mysqli_real_escape_string)
|
||||
PHP_ME_MAPPING(prepare, mysqli_prepare, arginfo_class_mysqli_prepare, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(query, mysqli_query, arginfo_class_mysqli_query, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(real_connect, mysqli_real_connect, arginfo_class_mysqli_real_connect, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(real_escape_string, mysqli_real_escape_string, arginfo_class_mysqli_real_escape_string, ZEND_ACC_PUBLIC)
|
||||
#if defined(MYSQLI_USE_MYSQLND)
|
||||
PHP_FALIAS(reap_async_query, mysqli_reap_async_query, arginfo_mysqli_no_params)
|
||||
PHP_ME_MAPPING(reap_async_query, mysqli_reap_async_query, arginfo_mysqli_no_params, ZEND_ACC_PUBLIC)
|
||||
#endif
|
||||
PHP_FALIAS(escape_string, mysqli_real_escape_string, arginfo_class_mysqli_real_escape_string)
|
||||
PHP_FALIAS(real_query, mysqli_real_query, arginfo_class_mysqli_real_query)
|
||||
PHP_FALIAS(release_savepoint, mysqli_release_savepoint, arginfo_class_mysqli_release_savepoint)
|
||||
PHP_FALIAS(rollback, mysqli_rollback, arginfo_class_mysqli_rollback)
|
||||
PHP_FALIAS(savepoint, mysqli_savepoint, arginfo_class_mysqli_savepoint)
|
||||
PHP_FALIAS(select_db,mysqli_select_db, arginfo_class_mysqli_select_db)
|
||||
PHP_ME_MAPPING(escape_string, mysqli_real_escape_string, arginfo_class_mysqli_real_escape_string, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(real_query, mysqli_real_query, arginfo_class_mysqli_real_query, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(release_savepoint, mysqli_release_savepoint, arginfo_class_mysqli_release_savepoint, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(rollback, mysqli_rollback, arginfo_class_mysqli_rollback, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(savepoint, mysqli_savepoint, arginfo_class_mysqli_savepoint, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(select_db,mysqli_select_db, arginfo_class_mysqli_select_db, ZEND_ACC_PUBLIC)
|
||||
#ifdef HAVE_MYSQLI_SET_CHARSET
|
||||
PHP_FALIAS(set_charset, mysqli_set_charset, arginfo_class_mysqli_set_charset)
|
||||
PHP_ME_MAPPING(set_charset, mysqli_set_charset, arginfo_class_mysqli_set_charset, ZEND_ACC_PUBLIC)
|
||||
#endif
|
||||
PHP_FALIAS(set_opt, mysqli_options, arginfo_class_mysqli_options)
|
||||
PHP_FALIAS(ssl_set, mysqli_ssl_set, arginfo_class_mysqli_ssl_set)
|
||||
PHP_FALIAS(stat, mysqli_stat, arginfo_mysqli_no_params)
|
||||
PHP_FALIAS(stmt_init, mysqli_stmt_init, arginfo_mysqli_no_params)
|
||||
PHP_FALIAS(store_result, mysqli_store_result, arginfo_class_store_result)
|
||||
PHP_FALIAS(thread_safe, mysqli_thread_safe, arginfo_mysqli_no_params)
|
||||
PHP_FALIAS(use_result, mysqli_use_result, arginfo_mysqli_no_params)
|
||||
PHP_FALIAS(refresh,mysqli_refresh, arginfo_class_mysqli_refresh)
|
||||
PHP_ME_MAPPING(set_opt, mysqli_options, arginfo_class_mysqli_options, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(ssl_set, mysqli_ssl_set, arginfo_class_mysqli_ssl_set, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(stat, mysqli_stat, arginfo_mysqli_no_params, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(stmt_init, mysqli_stmt_init, arginfo_mysqli_no_params, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(store_result, mysqli_store_result, arginfo_class_store_result, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(thread_safe, mysqli_thread_safe, arginfo_mysqli_no_params, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(use_result, mysqli_use_result, arginfo_mysqli_no_params, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(refresh,mysqli_refresh, arginfo_class_mysqli_refresh, ZEND_ACC_PUBLIC)
|
||||
PHP_FE_END
|
||||
};
|
||||
/* }}} */
|
||||
@ -600,22 +600,22 @@ const zend_function_entry mysqli_link_methods[] = {
|
||||
* Every user visible function must have an entry in mysqli_result_functions[].
|
||||
*/
|
||||
const zend_function_entry mysqli_result_methods[] = {
|
||||
PHP_FALIAS(__construct, mysqli_result_construct, NULL)
|
||||
PHP_FALIAS(close, mysqli_free_result, arginfo_mysqli_no_params)
|
||||
PHP_FALIAS(free, mysqli_free_result, arginfo_mysqli_no_params)
|
||||
PHP_FALIAS(data_seek, mysqli_data_seek, arginfo_class_mysqli_data_seek)
|
||||
PHP_FALIAS(fetch_field, mysqli_fetch_field, arginfo_mysqli_no_params)
|
||||
PHP_FALIAS(fetch_fields, mysqli_fetch_fields, arginfo_mysqli_no_params)
|
||||
PHP_FALIAS(fetch_field_direct, mysqli_fetch_field_direct, arginfo_class_mysqli_result_and_fieldnr)
|
||||
PHP_ME_MAPPING(__construct, mysqli_result_construct, NULL, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(close, mysqli_free_result, arginfo_mysqli_no_params, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(free, mysqli_free_result, arginfo_mysqli_no_params, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(data_seek, mysqli_data_seek, arginfo_class_mysqli_data_seek, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(fetch_field, mysqli_fetch_field, arginfo_mysqli_no_params, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(fetch_fields, mysqli_fetch_fields, arginfo_mysqli_no_params, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(fetch_field_direct, mysqli_fetch_field_direct, arginfo_class_mysqli_result_and_fieldnr, ZEND_ACC_PUBLIC)
|
||||
#if defined(MYSQLI_USE_MYSQLND)
|
||||
PHP_FALIAS(fetch_all, mysqli_fetch_all, arginfo_class_mysqli_fetch_array)
|
||||
PHP_ME_MAPPING(fetch_all, mysqli_fetch_all, arginfo_class_mysqli_fetch_array, ZEND_ACC_PUBLIC)
|
||||
#endif
|
||||
PHP_FALIAS(fetch_array, mysqli_fetch_array, arginfo_class_mysqli_fetch_array)
|
||||
PHP_FALIAS(fetch_assoc, mysqli_fetch_assoc, arginfo_mysqli_no_params)
|
||||
PHP_FALIAS(fetch_object,mysqli_fetch_object, arginfo_class_mysqli_fetch_object)
|
||||
PHP_FALIAS(fetch_row, mysqli_fetch_row, arginfo_mysqli_no_params)
|
||||
PHP_FALIAS(field_seek, mysqli_field_seek, arginfo_class_mysqli_result_and_fieldnr)
|
||||
PHP_FALIAS(free_result, mysqli_free_result, arginfo_mysqli_no_params)
|
||||
PHP_ME_MAPPING(fetch_array, mysqli_fetch_array, arginfo_class_mysqli_fetch_array, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(fetch_assoc, mysqli_fetch_assoc, arginfo_mysqli_no_params, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(fetch_object,mysqli_fetch_object, arginfo_class_mysqli_fetch_object, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(fetch_row, mysqli_fetch_row, arginfo_mysqli_no_params, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(field_seek, mysqli_field_seek, arginfo_class_mysqli_result_and_fieldnr, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(free_result, mysqli_free_result, arginfo_mysqli_no_params, ZEND_ACC_PUBLIC)
|
||||
PHP_FE_END
|
||||
};
|
||||
/* }}} */
|
||||
@ -625,29 +625,29 @@ const zend_function_entry mysqli_result_methods[] = {
|
||||
* Every user visible function must have an entry in mysqli_stmt_functions[].
|
||||
*/
|
||||
const zend_function_entry mysqli_stmt_methods[] = {
|
||||
PHP_FALIAS(__construct, mysqli_stmt_construct, NULL)
|
||||
PHP_FALIAS(attr_get, mysqli_stmt_attr_get, arginfo_class_mysqli_stmt_attr_get)
|
||||
PHP_FALIAS(attr_set,mysqli_stmt_attr_set, arginfo_class_mysqli_stmt_attr_set)
|
||||
PHP_FALIAS(bind_param,mysqli_stmt_bind_param, arginfo_class_mysqli_stmt_bind_param)
|
||||
PHP_FALIAS(bind_result,mysqli_stmt_bind_result, arginfo_class_mysqli_stmt_bind_result)
|
||||
PHP_FALIAS(close, mysqli_stmt_close, arginfo_mysqli_no_params)
|
||||
PHP_FALIAS(data_seek, mysqli_stmt_data_seek, arginfo_class_mysqli_data_seek)
|
||||
PHP_FALIAS(execute, mysqli_stmt_execute, arginfo_mysqli_no_params)
|
||||
PHP_FALIAS(fetch, mysqli_stmt_fetch, arginfo_mysqli_no_params)
|
||||
PHP_FALIAS(get_warnings, mysqli_stmt_get_warnings, arginfo_mysqli_no_params)
|
||||
PHP_FALIAS(result_metadata, mysqli_stmt_result_metadata, arginfo_mysqli_no_params)
|
||||
PHP_ME_MAPPING(__construct, mysqli_stmt_construct, NULL, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(attr_get, mysqli_stmt_attr_get, arginfo_class_mysqli_stmt_attr_get, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(attr_set,mysqli_stmt_attr_set, arginfo_class_mysqli_stmt_attr_set, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(bind_param,mysqli_stmt_bind_param, arginfo_class_mysqli_stmt_bind_param, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(bind_result,mysqli_stmt_bind_result, arginfo_class_mysqli_stmt_bind_result, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(close, mysqli_stmt_close, arginfo_mysqli_no_params, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(data_seek, mysqli_stmt_data_seek, arginfo_class_mysqli_data_seek, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(execute, mysqli_stmt_execute, arginfo_mysqli_no_params, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(fetch, mysqli_stmt_fetch, arginfo_mysqli_no_params, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(get_warnings, mysqli_stmt_get_warnings, arginfo_mysqli_no_params, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(result_metadata, mysqli_stmt_result_metadata, arginfo_mysqli_no_params, ZEND_ACC_PUBLIC)
|
||||
#if defined(MYSQLI_USE_MYSQLND)
|
||||
PHP_FALIAS(more_results, mysqli_stmt_more_results, arginfo_mysqli_no_params)
|
||||
PHP_FALIAS(next_result, mysqli_stmt_next_result, arginfo_mysqli_no_params)
|
||||
PHP_ME_MAPPING(more_results, mysqli_stmt_more_results, arginfo_mysqli_no_params, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(next_result, mysqli_stmt_next_result, arginfo_mysqli_no_params, ZEND_ACC_PUBLIC)
|
||||
#endif
|
||||
PHP_FALIAS(num_rows, mysqli_stmt_num_rows, arginfo_mysqli_no_params)
|
||||
PHP_FALIAS(send_long_data, mysqli_stmt_send_long_data, arginfo_class_mysqli_stmt_send_long_data)
|
||||
PHP_FALIAS(free_result, mysqli_stmt_free_result, arginfo_mysqli_no_params)
|
||||
PHP_FALIAS(reset, mysqli_stmt_reset, arginfo_mysqli_no_params)
|
||||
PHP_FALIAS(prepare, mysqli_stmt_prepare, arginfo_class_mysqli_prepare)
|
||||
PHP_FALIAS(store_result, mysqli_stmt_store_result, arginfo_mysqli_no_params)
|
||||
PHP_ME_MAPPING(num_rows, mysqli_stmt_num_rows, arginfo_mysqli_no_params, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(send_long_data, mysqli_stmt_send_long_data, arginfo_class_mysqli_stmt_send_long_data, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(free_result, mysqli_stmt_free_result, arginfo_mysqli_no_params, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(reset, mysqli_stmt_reset, arginfo_mysqli_no_params, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(prepare, mysqli_stmt_prepare, arginfo_class_mysqli_prepare, ZEND_ACC_PUBLIC)
|
||||
PHP_ME_MAPPING(store_result, mysqli_stmt_store_result, arginfo_mysqli_no_params, ZEND_ACC_PUBLIC)
|
||||
#if defined(MYSQLI_USE_MYSQLND)
|
||||
PHP_FALIAS(get_result, mysqli_stmt_get_result, arginfo_mysqli_no_params)
|
||||
PHP_ME_MAPPING(get_result, mysqli_stmt_get_result, arginfo_mysqli_no_params, ZEND_ACC_PUBLIC)
|
||||
#endif
|
||||
PHP_FE_END
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user