Home >Backend Development >PHP Tutorial >如何知道PHP自带函数底层都做了什么

如何知道PHP自带函数底层都做了什么

WBOY
WBOYOriginal
2016-06-06 20:50:581168browse

该怎么开始呢

回复内容:

该怎么开始呢

1. 下载php源码,先学会编译php
2. 找个教程学习如何写php的扩展,由此切入Zend
3. 找到你想看的内置函数源码。如果不知道在哪里,可以用grep来找。

$ find -name \*.c -exec grep {} -Hne "PHP_FUNCTION (array_push" \;
./ext/standard/array.c:2054:PHP_FUNCTION(array_push)

推荐 深入理解PHP内核

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn