Máté Kocsis
ed6e289c31
Make the return type of some stream context related functions true ( #12720 )
...
Co-authored-by: Niels Dossche <7771979+nielsdos@users.noreply.github.com >
2023-11-19 20:36:42 +01:00
David CARLIER
931a8b0739
inet_ntop requirement check at configure time instead ( #12700 )
2023-11-17 16:01:46 +00:00
HypeMC
f25474f7f2
Add before_needle argument to strrchr()
...
Closes GH-11430
2023-08-24 14:26:46 +01:00
Máté Kocsis
a5ad7e09d5
Implement stream_context_set_options()
2023-07-18 12:59:21 +02:00
George Peter Banyard
d8696f9216
[RFC] Path to Saner Increment/Decrement operators ( #10358 )
...
* Add behavioural tests for incdec operators
* Add support to ++/-- for objects castable to _IS_NUMBER
* Add str_increment() function
* Add str_decrement() function
RFC: https://wiki.php.net/rfc/saner-inc-dec-operators
Co-authored-by: Ilija Tovilo <ilija.tovilo@me.com >
Co-authored-by: Arnaud Le Blanc <arnaud.lb@gmail.com >
2023-07-17 15:51:24 +01:00
George Peter Banyard
3d4ff5ae22
RFC: Deprecate remains of string evaluated code assertions ( #11671 )
...
Link: https://wiki.php.net/rfc/assert-string-eval-cleanup
2023-07-13 15:45:32 +01:00
George Peter Banyard
798c40a739
[RFC] Define proper semantics for range() function ( #10826 )
...
RFC: https://wiki.php.net/rfc/proper-range-semantics
2023-06-19 14:25:26 +01:00
Michael Voříšek
bd03c0343e
Allow CTE on more CTE safe functions ( #10771 )
2023-05-16 21:59:26 +02:00
Máté Kocsis
85338569de
Narrow bool return types to true when possible
2023-05-07 19:34:09 +02:00
Michael Voříšek
1209f593ca
Allow CTE on basic type/math functions ( #10842 )
2023-04-24 22:39:20 +02:00
Niels Dossche
c822c2dddd
Merge branch 'PHP-8.2'
...
* PHP-8.2:
Remove CTE flag from array_diff_ukey(), which was added by mistake
Fix missing and inconsistent error check on SQLAllocHandle
2023-03-15 21:47:34 +01:00
Michael Voříšek
5239f9fc86
Remove CTE flag from array_diff_ukey(), which was added by mistake
...
This was accidentally added in GH-7780, but since it takes a callable
argument, this flag is useless on this function.
Closes GH-10859.
2023-03-15 21:40:11 +01:00
Niels Dossche
b39ff334a3
Merge branch 'PHP-8.2'
...
* PHP-8.2:
Re-add some CTE functions that were removed from being CTE by a mistake
Fix GH-8065: opcache.consistency_checks > 0 causes segfaults in PHP >= 8.1.5 in fpm context
Fix GH-8646: Memory leak PHP FPM 8.1
2023-03-07 20:36:41 +01:00
Michael Voříšek
411cd04541
Re-add some CTE functions that were removed from being CTE by a mistake
...
These functions were accidentally removed from being CTE in GH-7780.
This patch brings them back.
Closes GH-10768.
2023-03-07 20:30:11 +01:00
Máté Kocsis
a4fd2609ce
Declare ext/standard constants in stubs - part 9 ( #9717 )
2022-10-13 13:13:36 +02:00
Máté Kocsis
c59e94fc9d
Declare ext/stanard constants in stubs - part 11 ( #9728 )
2022-10-12 12:07:03 +02:00
Máté Kocsis
433ed0973a
Declare ext/standard constants in stubs - part 10 ( #9719 )
2022-10-12 08:16:19 +02:00
Máté Kocsis
ed0f1f04b9
Declare ext/standard constants in stubs - part 8 ( #9615 )
2022-09-30 13:51:18 +02:00
Máté Kocsis
3227d04fa9
Declare ext/standard constants in stubs - part 7 ( #9505 )
2022-09-08 13:57:07 +02:00
Máté Kocsis
c547fc183c
Add support for validation of missing class synopses ( #9472 )
2022-09-05 14:21:15 +02:00
Máté Kocsis
e733ebf30e
Add parenthesis around preprocessor conditions in stubs
...
gen_stub.php concatenates nested #ifs into one #if so let's make sure the semantics remain the same.
2022-09-02 16:21:28 +02:00
Máté Kocsis
cfa72ff3af
Declare ext/standard constants in stubs - part 6
...
Closes GH-9467
2022-09-02 16:07:25 +02:00
Máté Kocsis
6f2f228e4a
Declare ext/standard constants in stubs - part 5
...
Closes GH-9466
2022-09-02 15:04:49 +02:00
Máté Kocsis
64b962b241
Declare ext/standard constants in stubs - part 4
...
Closes GH-9465
2022-09-02 12:41:51 +02:00
Tim Düsterhus
c77bbf6fe5
Mark crypt()'s $string parameter as #[\SensitiveParameter]
2022-08-30 20:02:28 +02:00
Máté Kocsis
adb45a63c0
Fix GH-9186 @strict-properties can be bypassed using unserialization ( #9354 )
...
* Emit deprecation warnings when adding dynamic properties to classes during unserialization - this will become an Error in php 9.0.
(Adding dynamic properties in other contexts was already a deprecation warning - the use case of unserialization was overlooked)
* Throw an error when attempting to add a dynamic property to a `readonly` class when unserializing
* Add new serialization methods `__serialize`/`__unserialize` for SplFixedArray to avoid creating deprecated dynamic
properties that would then be added to the backing fixed-size array
* Don't add named dynamic/declared properties (e.g. $obj->foo) of SplFixedArray to the backing array when unserializing
* Update tests to declare properties or to expect the deprecation warning
* Add news entry
Co-authored-by: Tyson Andre <tysonandre775@hotmail.com >
2022-08-30 07:46:32 -04:00
Máté Kocsis
ef72d53397
Declare ext/standard constants in stubs - part 3 ( #9427 )
2022-08-26 14:47:34 +02:00
Máté Kocsis
bc4c012611
Declare ext/standard constants in stubs - part 1 ( #9404 )
2022-08-24 16:09:48 +02:00
Ilija Tovilo
98bdb7f99b
Make pestr[n]dup infallible ( #9295 )
...
Fixes GH-9128
Closes GH-9295
2022-08-12 12:21:14 +02:00
Michael Voříšek
b0c0a2cfb4
Use -1 "precision" in gen_stub.php
...
Closes GH-8734.
2022-07-23 12:09:37 +02:00
Máté Kocsis
e328c68305
Rename @cname to @cvalue in stubs ( #9043 )
...
@cname currently refers to the constant name in C. However, it is not always a (constant) name, but sometimes a function invocation, so naming it as @cvalue would be more appropriate.
2022-07-19 15:11:42 +02:00
Go Kudo
4d8dd8d258
Implement Random Extension
...
https://wiki.php.net/rfc/rng_extension
https://wiki.php.net/rfc/random_extension_improvement
2022-07-19 10:27:38 +01:00
Ilija Tovilo
63912b5ecd
Fix RC func info of str_split ( #9016 )
...
Introduced in GH-8945
With RETURN_EMPTY_ARRAY this function can now return an interned array which
has refcount 2.
2022-07-15 11:23:55 +02:00
Tim Düsterhus
342e18f105
Support the actual #[\SensitiveParameter] attribute in stubs ( #8836 )
2022-07-12 12:43:44 +02:00
Dennis Snell
492af9f88e
Add ini_parse_quantity function to convert ini quantities shorthand notation to int ( #8454 )
2022-07-10 14:48:52 +02:00
Máté Kocsis
49d3dde211
Declare true return types ( #8759 )
2022-06-18 22:06:50 +02:00
Tim Düsterhus
13758965b2
Mark parameter in ext/standard as sensitive
...
No changes to the stubs required, password_hash and password_verify were added
to the initial version of the stub support.
2022-06-13 11:09:12 +02:00
Rowan Tommins
d9f3ca705c
Add deprecation notices to utf8_encode and utf8_decode
...
Implements initial stage of accepted RFC to remove them:
https://wiki.php.net/rfc/remove_utf8_decode_and_utf8_encode
Tests relating to SOAP and htmlspecialchars seem to have been
using this entirely unnecessarily, so have been fixed.
Closes GH-8726.
2022-06-12 13:37:23 +02:00
Máté Kocsis
debd38f851
Add support for sensitive parameters in stubs
2022-06-04 18:15:05 +02:00
Máté Kocsis
14da1cb909
Add support for class constants in stubs ( #7434 )
2022-05-22 22:27:23 +02:00
George Peter Banyard
8649cb8a96
Improve and fix stub return types ( #8368 )
2022-04-14 18:38:00 +01:00
Christoph M. Becker
53c6619bda
Restore memory_reset_peak_usage() declaration
...
Cf. <https://github.com/php/php-src/pull/8151/files#r819605725 >.
2022-04-01 18:13:22 +02:00
George Peter Banyard
083b64efb5
Add missing #endif in stubs
...
This slipped away during the rebase of 5171cb435a
2022-04-01 16:26:38 +01:00
George Peter Banyard
5171cb435a
Fix [-Wundef] warnings in standard extension
2022-04-01 15:48:41 +01:00
Nikita Popov
c4334fc616
Remove special chr/count handling in sccp function evaluation
...
These can be handled by the generic code. Worth noting that count
will usually go through ZEND_COUNT, and chr on constants is
evaluated in the compiler, so these are not particularly compile-time
sensitive either.
2021-12-26 09:55:18 +01:00
Christoph M. Becker
5ddf191da2
Merge branch 'PHP-8.1'
...
* PHP-8.1:
$context parameter of get_headers() is nullable
2021-12-23 11:50:53 +01:00
Christoph M. Becker
ccd7d410f1
Merge branch 'PHP-8.0' into PHP-8.1
...
* PHP-8.0:
$context parameter of get_headers() is nullable
2021-12-23 11:49:33 +01:00
Christoph M. Becker
c5f4ee50ab
$context parameter of get_headers() is nullable
...
Closes GH-7813.
2021-12-23 11:47:20 +01:00
Tyson Andre
32e2d97a26
Allow internal functions to declare if they support compile-time evaluation, add functions. ( #7780 )
...
https://wiki.php.net/rfc/strtolower-ascii means that these functions no longer
depend on the current locale in php 8.2. Before that, this was unsafe to
evaluate at compile time.
Followup to GH-7506
Add strcmp/strcasecmp/strtolower/strtoupper functions
Add bin2hex/hex2bin and related functions
Update test of garbage collection using strtolower to use something else to create a refcounted string
2021-12-20 09:27:06 -05:00
Máté Kocsis
220f0f55cf
Merge branch 'PHP-8.0' into PHP-8.1
...
* PHP-8.0:
Fix the return type of imagecolorexactalpha()
String default values are enclosed in quotes rather than apostrophes
2021-10-12 09:53:30 +02:00