I am trying to compile APCu cache extension using make && make install.
I get a compilation error regarding not being able to find zend_string
or zend_long
. Do you guys know what extension I would need for these?
Thanks :)
While a zend_string_dup () function that performs an actual copy of the string (rather than only a refcount increment) also exists, the behavior is often considered confusing, because it only copies non-immutable strings. If you want to force a copy of a string, you are better off creating a new one using zend_string_init ().
This means that the zend_string header and the string contents are combined into a single allocation, which is more efficient than using two separate ones. You will find that PHP uses the struct hack in quite a number of places where a fixed-size header is combined with a dynamic amount of data.
As PHP supports strings that contain null bytes, PHP needs to explicitly store the length of the string. Additionally, PHP needs strings to fit into its general framework of reference-counted structures. This is the purpose of the zend_string type.
The "Type 'unknown' is not assignable to type" error occurs when we try to assign a value with a type of `unknown` to a value of a different type. To solve the error, use a type assertion or a type guard to verify that the two values have compatible types before the assignment. HomeAboutContacts HomeAboutContacts GitHubLinkedinTwitter
Those types only exist in PHP 7/Zend Engine 3. You need the PHP 5 version of the extension.
I try to run:
./configure --with-php-config=/usr/local/php7/bin/php-config
replace
./configure
Success.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With