diff options
author | Nikita Popov <nikita.ppv@gmail.com> | 2020-02-21 15:33:58 +0100 |
---|---|---|
committer | Nikita Popov <nikita.ppv@gmail.com> | 2020-02-25 10:21:31 +0100 |
commit | bb6e2a1615a54bc2986c782a2541289fd33a1bbb (patch) | |
tree | 9d483556fb2f11759c33aea28fffc135344ce27a | |
parent | 7956866ff45bb8bf9cb01010e1f3013dd8a7621d (diff) | |
download | php-git-bb6e2a1615a54bc2986c782a2541289fd33a1bbb.tar.gz |
Avoid used of "named fn" in ext/standard
-rwxr-xr-x | ext/standard/basic_functions.c | 32 | ||||
-rw-r--r-- | ext/standard/basic_functions.h | 6 | ||||
-rw-r--r-- | ext/standard/crc32.c | 2 | ||||
-rw-r--r-- | ext/standard/dir.c | 4 | ||||
-rw-r--r-- | ext/standard/file.c | 8 | ||||
-rw-r--r-- | ext/standard/file.h | 8 | ||||
-rw-r--r-- | ext/standard/filestat.c | 4 | ||||
-rw-r--r-- | ext/standard/formatted_print.c | 4 | ||||
-rw-r--r-- | ext/standard/md5.c | 4 | ||||
-rw-r--r-- | ext/standard/md5.h | 4 | ||||
-rw-r--r-- | ext/standard/php_dir.h | 2 | ||||
-rw-r--r-- | ext/standard/php_filestat.h | 4 | ||||
-rw-r--r-- | ext/standard/php_string.h | 4 |
13 files changed, 43 insertions, 43 deletions
diff --git a/ext/standard/basic_functions.c b/ext/standard/basic_functions.c index a55e58f565..e0b7760477 100755 --- a/ext/standard/basic_functions.c +++ b/ext/standard/basic_functions.c @@ -146,9 +146,9 @@ static const zend_function_entry basic_functions[] = { /* {{{ */ PHP_FE(get_html_translation_table, arginfo_get_html_translation_table) PHP_FE(sha1, arginfo_sha1) PHP_FE(sha1_file, arginfo_sha1_file) - PHP_NAMED_FE(md5,php_if_md5, arginfo_md5) - PHP_NAMED_FE(md5_file,php_if_md5_file, arginfo_md5_file) - PHP_NAMED_FE(crc32,php_if_crc32, arginfo_crc32) + PHP_FE(md5, arginfo_md5) + PHP_FE(md5_file, arginfo_md5_file) + PHP_FE(crc32, arginfo_crc32) PHP_FE(iptcparse, arginfo_iptcparse) PHP_FE(iptcembed, arginfo_iptcembed) @@ -235,8 +235,8 @@ static const zend_function_entry basic_functions[] = { /* {{{ */ PHP_FE(str_pad, arginfo_str_pad) PHP_FALIAS(chop, rtrim, arginfo_chop) PHP_FALIAS(strchr, strstr, arginfo_strchr) - PHP_NAMED_FE(sprintf, PHP_FN(user_sprintf), arginfo_sprintf) - PHP_NAMED_FE(printf, PHP_FN(user_printf), arginfo_printf) + PHP_FE(sprintf, arginfo_sprintf) + PHP_FE(printf, arginfo_printf) PHP_FE(vprintf, arginfo_vprintf) PHP_FE(vsprintf, arginfo_vsprintf) PHP_FE(fprintf, arginfo_fprintf) @@ -361,10 +361,10 @@ static const zend_function_entry basic_functions[] = { /* {{{ */ PHP_FE(fdiv, arginfo_fdiv) PHP_FE(intdiv, arginfo_intdiv) #ifdef HAVE_INET_NTOP - PHP_RAW_NAMED_FE(inet_ntop, zif_inet_ntop, arginfo_inet_ntop) + PHP_FE(inet_ntop, arginfo_inet_ntop) #endif #ifdef HAVE_INET_PTON - PHP_RAW_NAMED_FE(inet_pton, php_inet_pton, arginfo_inet_pton) + PHP_FE(inet_pton, arginfo_inet_pton) #endif PHP_FE(ip2long, arginfo_ip2long) PHP_FE(long2ip, arginfo_long2ip) @@ -517,10 +517,10 @@ static const zend_function_entry basic_functions[] = { /* {{{ */ PHP_FE(fgetc, arginfo_fgetc) PHP_FE(fgets, arginfo_fgets) PHP_FE(fread, arginfo_fread) - PHP_NAMED_FE(fopen, php_if_fopen, arginfo_fopen) + PHP_FE(fopen, arginfo_fopen) PHP_FE(fpassthru, arginfo_fpassthru) - PHP_NAMED_FE(ftruncate, php_if_ftruncate, arginfo_ftruncate) - PHP_NAMED_FE(fstat, php_if_fstat, arginfo_fstat) + PHP_FE(ftruncate, arginfo_ftruncate) + PHP_FE(fstat, arginfo_fstat) PHP_FE(fseek, arginfo_fseek) PHP_FE(ftell, arginfo_ftell) PHP_FE(fflush, arginfo_fflush) @@ -530,7 +530,7 @@ static const zend_function_entry basic_functions[] = { /* {{{ */ PHP_FE(rename, arginfo_rename) PHP_FE(copy, arginfo_copy) PHP_FE(tempnam, arginfo_tempnam) - PHP_NAMED_FE(tmpfile, php_if_tmpfile, arginfo_tmpfile) + PHP_FE(tmpfile, arginfo_tmpfile) PHP_FE(file, arginfo_file) PHP_FE(file_get_contents, arginfo_file_get_contents) PHP_FE(file_put_contents, arginfo_file_put_contents) @@ -629,7 +629,7 @@ static const zend_function_entry basic_functions[] = { /* {{{ */ PHP_FE(getcwd, arginfo_getcwd) PHP_FE(rewinddir, arginfo_rewinddir) - PHP_NAMED_FE(readdir, php_if_readdir, arginfo_readdir) + PHP_FE(readdir, arginfo_readdir) PHP_FALIAS(dir, getdir, arginfo_dir) PHP_FE(scandir, arginfo_scandir) #ifdef HAVE_GLOB @@ -653,8 +653,8 @@ static const zend_function_entry basic_functions[] = { /* {{{ */ PHP_FE(is_file, arginfo_is_file) PHP_FE(is_dir, arginfo_is_dir) PHP_FE(is_link, arginfo_is_link) - PHP_NAMED_FE(stat, php_if_stat, arginfo_stat) - PHP_NAMED_FE(lstat, php_if_lstat, arginfo_lstat) + PHP_FE(stat, arginfo_stat) + PHP_FE(lstat, arginfo_lstat) PHP_FE(chown, arginfo_chown) PHP_FE(chgrp, arginfo_chgrp) #if HAVE_LCHOWN @@ -1301,7 +1301,7 @@ PHP_FUNCTION(constant) #ifdef HAVE_INET_NTOP /* {{{ proto string|false inet_ntop(string in_addr) Converts a packed inet address to a human readable IP address string */ -PHP_NAMED_FUNCTION(zif_inet_ntop) +PHP_FUNCTION(inet_ntop) { char *address; size_t address_len; @@ -1333,7 +1333,7 @@ PHP_NAMED_FUNCTION(zif_inet_ntop) #ifdef HAVE_INET_PTON /* {{{ proto string|false inet_pton(string ip_address) Converts a human readable IP address to a packed binary string */ -PHP_NAMED_FUNCTION(php_inet_pton) +PHP_FUNCTION(inet_pton) { int ret, af = AF_INET; char *address; diff --git a/ext/standard/basic_functions.h b/ext/standard/basic_functions.h index 1366998983..31325fea12 100644 --- a/ext/standard/basic_functions.h +++ b/ext/standard/basic_functions.h @@ -52,10 +52,10 @@ PHP_FUNCTION(time_sleep_until); #endif PHP_FUNCTION(flush); #ifdef HAVE_INET_NTOP -PHP_NAMED_FUNCTION(zif_inet_ntop); +PHP_FUNCTION(inet_ntop); #endif #ifdef HAVE_INET_PTON -PHP_NAMED_FUNCTION(php_inet_pton); +PHP_FUNCTION(inet_pton); #endif PHP_FUNCTION(ip2long); PHP_FUNCTION(long2ip); @@ -108,7 +108,7 @@ PHP_FUNCTION(getservbyport); PHP_FUNCTION(getprotobyname); PHP_FUNCTION(getprotobynumber); -PHP_NAMED_FUNCTION(php_if_crc32); +PHP_FUNCTION(crc32); PHP_FUNCTION(register_tick_function); PHP_FUNCTION(unregister_tick_function); diff --git a/ext/standard/crc32.c b/ext/standard/crc32.c index 1393483278..a0e5d6d816 100644 --- a/ext/standard/crc32.c +++ b/ext/standard/crc32.c @@ -70,7 +70,7 @@ static uint32_t crc32_aarch64(uint32_t crc, char *p, size_t nr) { /* {{{ proto string crc32(string str) Calculate the crc32 polynomial of a string */ -PHP_NAMED_FUNCTION(php_if_crc32) +PHP_FUNCTION(crc32) { char *p; size_t nr; diff --git a/ext/standard/dir.c b/ext/standard/dir.c index 5554a689b3..e6caf7109d 100644 --- a/ext/standard/dir.c +++ b/ext/standard/dir.c @@ -90,7 +90,7 @@ static zend_class_entry *dir_class_entry_ptr; static const zend_function_entry php_dir_class_functions[] = { PHP_FALIAS(close, closedir, arginfo_class_Directory_close) PHP_FALIAS(rewind, rewinddir, arginfo_class_Directory_rewind) - PHP_NAMED_FE(read, php_if_readdir, arginfo_class_Directory_read) + PHP_FALIAS(read, readdir, arginfo_class_Directory_read) PHP_FE_END }; @@ -385,7 +385,7 @@ PHP_FUNCTION(rewinddir) /* {{{ proto string|false readdir([resource dir_handle]) Read directory entry from dir_handle */ -PHP_NAMED_FUNCTION(php_if_readdir) +PHP_FUNCTION(readdir) { zval *id = NULL, *tmp, *myself; php_stream *dirp; diff --git a/ext/standard/file.c b/ext/standard/file.c index 473d0510c2..bdb56d5428 100644 --- a/ext/standard/file.c +++ b/ext/standard/file.c @@ -850,7 +850,7 @@ PHP_FUNCTION(tempnam) /* {{{ proto resource tmpfile(void) Create a temporary file that will be deleted automatically after use */ -PHP_NAMED_FUNCTION(php_if_tmpfile) +PHP_FUNCTION(tmpfile) { php_stream *stream; @@ -868,7 +868,7 @@ PHP_NAMED_FUNCTION(php_if_tmpfile) /* {{{ proto resource fopen(string filename, string mode [, bool use_include_path [, resource context]]) Open a file or a URL and return a file pointer */ -PHP_NAMED_FUNCTION(php_if_fopen) +PHP_FUNCTION(fopen) { char *filename, *mode; size_t filename_len, mode_len; @@ -1483,7 +1483,7 @@ PHP_FUNCTION(unlink) /* {{{ proto bool ftruncate(resource fp, int size) Truncate file to 'size' length */ -PHP_NAMED_FUNCTION(php_if_ftruncate) +PHP_FUNCTION(ftruncate) { zval *fp; zend_long size; @@ -1512,7 +1512,7 @@ PHP_NAMED_FUNCTION(php_if_ftruncate) /* {{{ proto array fstat(resource fp) Stat() on a filehandle */ -PHP_NAMED_FUNCTION(php_if_fstat) +PHP_FUNCTION(fstat) { zval *fp; zval stat_dev, stat_ino, stat_mode, stat_nlink, stat_uid, stat_gid, stat_rdev, diff --git a/ext/standard/file.h b/ext/standard/file.h index 4e368cf545..bcca86f9a3 100644 --- a/ext/standard/file.h +++ b/ext/standard/file.h @@ -23,8 +23,8 @@ PHP_MINIT_FUNCTION(file); PHP_MSHUTDOWN_FUNCTION(file); PHP_FUNCTION(tempnam); -PHP_NAMED_FUNCTION(php_if_tmpfile); -PHP_NAMED_FUNCTION(php_if_fopen); +PHP_FUNCTION(tmpfile); +PHP_FUNCTION(fopen); PHPAPI PHP_FUNCTION(fclose); PHP_FUNCTION(popen); PHP_FUNCTION(pclose); @@ -61,8 +61,8 @@ PHP_FUNCTION(realpath); #ifdef HAVE_FNMATCH PHP_FUNCTION(fnmatch); #endif -PHP_NAMED_FUNCTION(php_if_ftruncate); -PHP_NAMED_FUNCTION(php_if_fstat); +PHP_FUNCTION(ftruncate); +PHP_FUNCTION(fstat); PHP_FUNCTION(sys_get_temp_dir); PHP_MINIT_FUNCTION(user_streams); diff --git a/ext/standard/filestat.c b/ext/standard/filestat.c index 88821296fc..c391cef48a 100644 --- a/ext/standard/filestat.c +++ b/ext/standard/filestat.c @@ -1074,12 +1074,12 @@ FileFunction(PHP_FN(file_exists), FS_EXISTS) /* {{{ proto array lstat(string filename) Give information about a file or symbolic link */ -FileFunction(php_if_lstat, FS_LSTAT) +FileFunction(PHP_FN(lstat), FS_LSTAT) /* }}} */ /* {{{ proto array stat(string filename) Give information about a file */ -FileFunction(php_if_stat, FS_STAT) +FileFunction(PHP_FN(stat), FS_STAT) /* }}} */ /* {{{ proto bool realpath_cache_size() diff --git a/ext/standard/formatted_print.c b/ext/standard/formatted_print.c index c8d912793a..ad8a79960c 100644 --- a/ext/standard/formatted_print.c +++ b/ext/standard/formatted_print.c @@ -670,7 +670,7 @@ php_formatted_print_get_array(zval *array, int *argc) /* {{{ proto string sprintf(string format [, mixed arg1 [, mixed ...]]) Return a formatted string */ -PHP_FUNCTION(user_sprintf) +PHP_FUNCTION(sprintf) { zend_string *result; char *format; @@ -719,7 +719,7 @@ PHP_FUNCTION(vsprintf) /* {{{ proto int printf(string format [, mixed arg1 [, mixed ...]]) Output a formatted string */ -PHP_FUNCTION(user_printf) +PHP_FUNCTION(printf) { zend_string *result; size_t rlen; diff --git a/ext/standard/md5.c b/ext/standard/md5.c index 994ac1a1fe..2e2b5281da 100644 --- a/ext/standard/md5.c +++ b/ext/standard/md5.c @@ -40,7 +40,7 @@ PHPAPI void make_digest_ex(char *md5str, const unsigned char *digest, int len) / /* {{{ proto string md5(string str, [ bool raw_output]) Calculate the md5 hash of a string */ -PHP_NAMED_FUNCTION(php_if_md5) +PHP_FUNCTION(md5) { zend_string *arg; zend_bool raw_output = 0; @@ -68,7 +68,7 @@ PHP_NAMED_FUNCTION(php_if_md5) /* {{{ proto string md5_file(string filename [, bool raw_output]) Calculate the md5 hash of given filename */ -PHP_NAMED_FUNCTION(php_if_md5_file) +PHP_FUNCTION(md5_file) { char *arg; size_t arg_len; diff --git a/ext/standard/md5.h b/ext/standard/md5.h index a6aa4e7b0a..9463c13892 100644 --- a/ext/standard/md5.h +++ b/ext/standard/md5.h @@ -21,8 +21,8 @@ PHPAPI void make_digest(char *md5str, const unsigned char *digest); PHPAPI void make_digest_ex(char *md5str, const unsigned char *digest, int len); -PHP_NAMED_FUNCTION(php_if_md5); -PHP_NAMED_FUNCTION(php_if_md5_file); +PHP_FUNCTION(md5); +PHP_FUNCTION(md5_file); #include "ext/standard/basic_functions.h" diff --git a/ext/standard/php_dir.h b/ext/standard/php_dir.h index 9d91e50ef2..599ac738c0 100644 --- a/ext/standard/php_dir.h +++ b/ext/standard/php_dir.h @@ -28,7 +28,7 @@ PHP_FUNCTION(chroot); #endif PHP_FUNCTION(getcwd); PHP_FUNCTION(rewinddir); -PHP_NAMED_FUNCTION(php_if_readdir); +PHP_FUNCTION(readdir); PHP_FUNCTION(getdir); PHP_FUNCTION(glob); PHP_FUNCTION(scandir); diff --git a/ext/standard/php_filestat.h b/ext/standard/php_filestat.h index d978f46796..0e454ac208 100644 --- a/ext/standard/php_filestat.h +++ b/ext/standard/php_filestat.h @@ -39,8 +39,8 @@ PHP_FUNCTION(is_file); PHP_FUNCTION(is_dir); PHP_FUNCTION(is_link); PHP_FUNCTION(file_exists); -PHP_NAMED_FUNCTION(php_if_stat); -PHP_NAMED_FUNCTION(php_if_lstat); +PHP_FUNCTION(stat); +PHP_FUNCTION(lstat); PHP_FUNCTION(disk_total_space); PHP_FUNCTION(disk_free_space); PHP_FUNCTION(chown); diff --git a/ext/standard/php_string.h b/ext/standard/php_string.h index 2c3953b958..7753bb6b46 100644 --- a/ext/standard/php_string.h +++ b/ext/standard/php_string.h @@ -52,8 +52,8 @@ PHP_FUNCTION(ucwords); PHP_FUNCTION(strtr); PHP_FUNCTION(strrev); PHP_FUNCTION(hebrev); -PHP_FUNCTION(user_sprintf); -PHP_FUNCTION(user_printf); +PHP_FUNCTION(sprintf); +PHP_FUNCTION(printf); PHP_FUNCTION(vprintf); PHP_FUNCTION(vsprintf); PHP_FUNCTION(addcslashes); |