Commit Graph

902 Commits

Author SHA1 Message Date
Nikita Popov
148ee16ff3 Remove support for umich_ldap
Doesn't seem to exist anymore, and their website now redirects to
openldap.
2019-09-06 14:57:26 +02:00
Nikita Popov
025ff3b5a3 Remove nsldap support
The newest version we're checking (libssldap50) seems to be about
15 years out of date. We could add support for libssldap60 (also
unmainted, but more recent), but given how nobody has expressed any
interest in this, I'm going ahead and dropping this code.
2019-09-06 14:39:42 +02:00
Christoph M. Becker
61dcae50d5 Document opcache.preload_user directive 2019-09-03 14:08:17 +02:00
viest
5703943081 Deprecate AI_IDN_ALLOW_UNASSIGNED and AI_IDN_USE_STD3_ASCII_RULES
These flags have been deprecated in glibc 2.28, so we also
deprecate them in PHP.

As we can't deprecate constants, we can only check for their use
in socket_addrinfo_lookup().
2019-08-26 11:33:18 +02:00
Nikita Popov
d1157cbce1 Relax closure $this unbinding deprecation
Only deprecate unbinding of $this from a closure if $this is
syntactically used within the closure.

This is desired to support Laravel's macro system, see laravel/framework#29482.

This should still allow us to implement the performance improvements
we're interested in for PHP 8, without breaking existing use-cases.
2019-08-23 17:21:23 +02:00
Nikita Popov
8a4171ac45 Add UPGRADING note about stream_set_option() and includes
[ci skip]
2019-08-08 10:12:16 +02:00
Tyson Andre
99fe0471ed nit: Fix a typo in UPGRADING
Closes GH-4481
2019-07-27 23:14:07 +02:00
Theodore Brown
0e6e2297fc Fix typos in UPGRADING and improve wording in a few places
Closes GH-4478
2019-07-26 01:16:49 +02:00
Christoph M. Becker
e1c80d8ea7 Remove duplication 2019-07-25 19:09:21 +02:00
Matteo Beccati
5d3d2b9827 Addded missing NEWS/UPGRADING entries for PDO "??" escape 2019-07-25 16:30:28 +02:00
Nikita Popov
1cbcf0f4f1 Throw notice for plain wrapper fread/fwrite errors
Similar to what is done for socket read/write errors.
2019-07-25 10:42:10 +02:00
Nikita Popov
845d07b343 Add upgrading entries
[ci skip]
2019-07-22 17:56:16 +02:00
Nikita Popov
23bb9f4e2f Add deprecations to UPGRADING 2019-07-22 11:53:50 +02:00
rjhdby
d574df63dc Deprecate alternative array access syntax
RFC: https://wiki.php.net/rfc/deprecate_curly_braces_array_access
2019-07-19 10:06:10 +02:00
George Peter Banyard
3a5664fdfe Convert E_STRICT into E_NOTICE for htmlentities() function 2019-07-18 11:13:18 +02:00
Christoph M. Becker
3f23380361 Update NEWS and UPGRADING wrt. opcache.cache_id [ci skip] 2019-07-18 09:16:56 +02:00
Nikita Popov
c9acc90186 Support <?php followed by EOF
This is an annoying edge-case for canonicalization.
2019-07-16 11:53:48 +02:00
Nikita Popov
9ad094e371 Emit T_BAD_CHARACTER for unexpected characters
Avoid having holes in the token stream which are annoying and
inefficient to reconstruct on the consumer side.
2019-07-15 12:51:01 +02:00
Peter Kokot
f573ba1948 Update changelogs
- PHP-7.4 alpha, beta, RC versions already include bugs logged in the
  NEWS
- some links to RFCs
- php_error_docref0
2019-07-13 15:37:36 +02:00
Christoph M. Becker
76783a9bcc Update NEWS and UPGRADING wrt. ext/recode unbundling 2019-07-12 14:35:44 +02:00
Nikita Popov
6285bb52fa Support redirect+null descriptors in proc_open
This adds support for doing something like:

    [1 => ['pipe', 'w'], 2 => ['redirect', 1]]

This will make descriptor 2 on the child end a dup'd descriptor 1.
This is mainly useful in conjunction with shell-less mode, because
we don't have an easy way to do "2>&1" there.

Additionally we support:

    [1 => ['pipe', 'w'], 2 => ['null']]

Which would be the same as a >/dev/null or >nul redirect, depending
on platform.
2019-07-11 15:48:10 +02:00
Nikita Popov
c42b7dd6d3 Throw notice on array access on illegal type
No notice is thrown for list() accesses, because we did not come
to an agreement regarding patterns like

    while ([$key, $value] = yield $it->next()) { ... }

where silent null access may be desirable.

No effort is made to suppress multiple notices in access chains
likes $x[0][0][0], because the technical complexity this causes
does not seem worthwhile.

RFC: https://wiki.php.net/rfc/notice-for-non-valid-array-container
2019-07-10 12:02:14 +02:00
Peter Kokot
5017676438 Add zend.exception_ignore_args [ci skip] 2019-07-08 19:34:47 +02:00
Peter Kokot
0f0c6c617f Catch up with recent changes [ci skip]
- RFC about password_hash portability improvements added
- build system minor updates noted
- typos
2019-07-08 16:23:27 +02:00
Scott Dutton
d90cdbd9df Deprecate passing invalid character to base_convert etc
RFC: https://wiki.php.net/rfc/base_convert_improvements
2019-07-08 12:49:21 +02:00
Christoph M. Becker
338e1b245d Implement FR #77230: Support custom CFLAGS and LDFLAGS from environment
While it is already possible to *set* CFLAGS and LDFLAGS (actually all
variables) from the environment for `nmake` (by passing the `/E`
option), it is not possible to *add* any (C|LD)FLAGS, which can be
useful in some cases.  Instead of allowing this for `nmake`, we add
support for additional custom (C|LD)FLAGS to `configure`, similar to
how that works on Linux, so one could actually write:
````
set CFLAGS=foo & set LDFLAGS=bar & configure
````
This also allows us to use these flags during configure.
2019-07-08 10:46:51 +02:00
Joe Watkins
0819e6dc9b
simple ignore arguments in exceptions implementation 2019-07-02 13:18:39 +02:00
Robert Kopack
b546ae986a Implement SQLite extended result code functionality 2019-07-02 13:03:35 +02:00
Sjon Hortensius
a7881df281 PDO: support username & password specified in DSN 2019-07-02 12:09:38 +02:00
Peter Kokot
aeaee62d92 Update changelogs [ci skip] 2019-07-01 01:35:29 +02:00
Nikita Popov
8be051015e Add support for proc_open() with a command array
In this case the progarm will be executed directly, without a shell.
On Linux the arguments are passed directly to execvp and no escaping
is necessary. On Windows we construct a command string using escaping
with the default Windows command-line argument parsing method described
at https://docs.microsoft.com/en-us/cpp/cpp/parsing-cpp-command-line-arguments.

Apart from avoiding the issue of argument escaping, passing an array
and bypassing shell has the advantage of allowing proper signal
delivery to the opened process (rather than the shell).
2019-06-28 11:09:55 +02:00
Peter Kokot
35b6a9f75a Catch up with some recent changes [ci skip]
- Mention mysqli::stat()
- Mention removal of HAVE_* for always defined extensions
- Mention removed symbols defined during the build
2019-06-28 00:29:50 +02:00
Christoph M. Becker
81fd113506 Support TGA reading
We add PHP bindings for libgd's features to read TGA files, which are
available as of libgd 2.1.0.

As PHP's bundled libgd doesn't yet include the respective features of the
external libgd, we add these.

Since TGA has no easily recognizable file signature, we don't add TGA
support for imagecreatefromstring() or getimagesize() and friends.
2019-06-20 23:40:51 +02:00
BohwaZ
ce22ccc77b Implement SQLite3 backup API 2019-06-17 23:34:51 +02:00
Theodore Brown
f74109d9a4 Implement numeric literal separators
RFC: https://wiki.php.net/rfc/numeric_literal_separator
2019-06-14 11:37:04 +02:00
Nikita Popov
19e2101dfa Revert "ext/standard: Use PKG_CHECK_MODULES to detect the Argon2 library"
This reverts commit bdcef51bcb.

It seems that pkg-config support for libargon2 is still flaky:
 * No pc file on Alpine.
 * Custom builds of released libargon2 versions create a broken
   pc file. This is fixed in master, but not released.

Go back to the old detection code for now.
2019-06-13 16:53:05 +02:00
Nikita Popov
b654a07492 Revert option rename
Let's keep this at --with-password-argon2 to avoid churn, I don't
think we have a strong motivation to rename this one.
2019-06-12 09:28:25 +02:00
Hugh McMaster
9d61036651 ext/ldap: Use PKG_CHECK_MODULES to detect the libsasl2 library 2019-06-11 17:11:53 +02:00
Nikita Popov
8f8fcbbd39 Support full variance if autoloading is used
Keep track of delayed variance obligations and check them after
linking a class is otherwise finished. Obligations may either be
unresolved method compatibility (because the necessecary classes
aren't available yet) or open parent/interface dependencies. The
latter occur because we allow the use of not fully linked classes
as parents/interfaces now.

An important aspect of the implementation is we do not require
classes involved in variance checks to be fully linked in order for
the class to be fully linked. Because the involved types do have to
exist in the class table (as partially linked classes) and we do
check these for correct variance, we have the guarantee that either
those classes will successfully link lateron or generate an error,
but there is no way to actually use them until that point and as
such no possibility of violating the variance contract. This is
important because it ensures that a class declaration always either
errors or will produce an immediately usable class afterwards --
there are no cases where the finalization of the class declaration
has to be delayed until a later time, as earlier variants of this
patch did.

Because variance checks deal with classes in various stages of
linking, we need to use a special instanceof implementation that
supports this, and also introduce finer-grained flags that tell us
which parts have been linked already and which haven't.

Class autoloading for variance checks is delayed into a separate
stage after the class is otherwise linked and before delayed
variance obligations are processed. This separation is needed to
handle cases like A extends B extends C, where B is the autoload
root, but C is required to check variance. This could end up
loading C while the class structure of B is in an inconsistent
state.
2019-06-11 13:09:33 +02:00
Nikita Popov
eecd8961d9 Add get_mangled_object_vars() function 2019-06-11 10:28:29 +02:00
Hugh McMaster
ab66179227 ext/xsl: Use PKG_CHECK_MODULES to detect the XSLT library 2019-06-07 09:35:12 +02:00
Nikita Popov
b964298c19 Deprecate ReflectionType::__toString()
We weren't able to do this in 7.1 because the deprecation notice
may be converted to an exception and __toString() can't throw,
which means that it ultimately become a fatal error. This issue
is resolved now, so we can mark the method as deprecated.
2019-06-05 15:33:52 +02:00
Nikita Popov
a31f46421d Allow exceptions in __toString()
RFC: https://wiki.php.net/rfc/tostring_exceptions

And convert some object to string conversion related recoverable
fatal errors into Error exceptions.

Improve exception safety of internal code performing string
conversions.
2019-06-05 14:25:07 +02:00
Remi Collet
8f854c1099 keep DIR option to --with-unixODBC for old versions without libodbc.pc 2019-06-05 10:56:10 +02:00
Joe Watkins
cf9fd3735a
remove reverted commit from changelog 2019-06-03 11:25:33 +02:00
Thomas Gerbet
bfc10978ef SimpleXMLElement and ResourceBundle implement Countable
Both classes already have a count() method and are considered
countable by \is_countable().
2019-05-31 18:59:19 +02:00
Dik Takken
77cf3d7b11 Allow array_merge() / array_merge_recursive() without arguments
This allows writing

    array_merge(...$arrays)

instead of

    array_merge([], ...$arrays)

and is in line with similar changes to array_push() and array_unshift()
in PHP 7.3.

Closes GH-4175.
2019-05-28 11:14:15 +02:00
Hugh McMaster
a8f4e8fe73 ext/xml: Use PKG_CHECK_MODULES to detect the Expat library 2019-05-27 15:16:42 +02:00
Nikita Popov
32f87bb575 Add UPGRADING/NEWS entries 2019-05-24 11:00:13 +02:00
Hugh McMaster
9df3e097b8 Use PKG_CHECK_MODULES to detect unixODBC 2019-05-22 09:04:05 +02:00