Commit Graph

116 Commits

Author SHA1 Message Date
Tim Düsterhus
29f98e7485
Replace @deprecated by #[\Deprecated] for internal functions / class constants (#14750)
Co-authored-by: Gina Peter Banyard <girgias@php.net>
Co-authored-by: Niels Dossche <7771979+nielsdos@users.noreply.github.com>
2024-07-10 16:47:31 +02:00
Arnaud Le Blanc
11accb5cdf
Preferably include from build dir (#13516)
* Include from build dir first

This fixes out of tree builds by ensuring that configure artifacts are included
from the build dir.

Before, out of tree builds would preferably include files from the src dir, as
the include path was defined as follows (ignoring includes from ext/ and sapi/) :

    -I$(top_builddir)/main
    -I$(top_srcdir)
    -I$(top_builddir)/TSRM
    -I$(top_builddir)/Zend
    -I$(top_srcdir)/main
    -I$(top_srcdir)/Zend
    -I$(top_srcdir)/TSRM
    -I$(top_builddir)/

As a result, an out of tree build would include configure artifacts such as
`main/php_config.h` from the src dir.

After this change, the include path is defined as follows:

    -I$(top_builddir)/main
    -I$(top_builddir)
    -I$(top_srcdir)/main
    -I$(top_srcdir)
    -I$(top_builddir)/TSRM
    -I$(top_builddir)/Zend
    -I$(top_srcdir)/Zend
    -I$(top_srcdir)/TSRM

* Fix extension include path for out of tree builds

* Include config.h with the brackets form

`#include "config.h"` searches in the directory containing the including-file
before any other include path. This can include the wrong config.h when building
out of tree and a config.h exists in the source tree.

Using `#include <config.h>` uses exclusively the include path, and gives
priority to the build dir.
2024-06-26 00:26:43 +02:00
Remi Collet
c75facb566
Merge branch 'PHP-8.2'
* PHP-8.2:
  Fix GH-11071: Revert "Fix [-Wundef] warning in INTL extension"
2023-04-18 11:05:23 +02:00
Remi Collet
f5dc2c31d9
Merge branch 'PHP-8.1' into PHP-8.2
* PHP-8.1:
  Fix GH-11071: Revert "Fix [-Wundef] warning in INTL extension"
2023-04-18 11:04:54 +02:00
Remi Collet
31e21f7dbc
Fix GH-11071: Revert "Fix [-Wundef] warning in INTL extension"
This reverts commit ea8686540a.
2023-04-18 11:04:28 +02:00
Tim Düsterhus
03fd405423
Use php_info_print_table_header for actual column headers only (#9485)
Using php_info_print_table_header() for "Foo: bar" looks odd and out of place,
because the whole line is colored. It is also questionable from a HTML
semantics point of view, because it does not described the columns that follow.

The use of this across extensions is inconsistent. It was part of the skeleton,
but ext/date or ext/json already use a regular row.
2022-09-06 08:48:22 +02:00
Máté Kocsis
66c4ade0fe
Declare ext/intl constants in stubs - part 14 (#9387) 2022-08-22 13:20:26 +02:00
Máté Kocsis
f743cb0f69
Declare ext/intl constants in stubs - part 13 (#9385) 2022-08-21 13:12:38 +02:00
Máté Kocsis
8fee9a3f11
Declare ext/intl constants in stubs - part 7 (#9269) 2022-08-08 14:24:22 +02:00
Máté Kocsis
d97f8eef33
Declare ext/intl constants in stubs - part 6 (#9268) 2022-08-08 14:21:48 +02:00
Máté Kocsis
614e9ec804
Declare ext/intl constants in stubs - part 5 (#9267) 2022-08-08 12:00:10 +02:00
Máté Kocsis
c1da9e7964
Declare ext/intl constants in stubs - part 4 (#9234) 2022-08-08 08:56:51 +02:00
Máté Kocsis
163a278a02
Declare ext/intl constants in stubs - part 3 (#9233) 2022-08-08 08:28:40 +02:00
Máté Kocsis
150456eaa2
Declare ext/intl constants in stubs - part 2 (#9219) 2022-08-02 16:55:12 +02:00
Máté Kocsis
0c225a2f57
Declare ext/intl constants in stubs - part 1 (#9205) 2022-07-30 18:11:20 +02:00
Patrick Allaert
aff365871a Fixed some spaces used instead of tabs 2021-06-29 11:30:26 +02:00
deltragon
ae9f6e7a8f
Add IntlDatePatternGenerator (#6771)
Add IntlDatePatternGenerator class per RFC https://wiki.php.net/rfc/intldatetimepatterngenerator.
2021-06-10 12:36:38 +02:00
KsaR
01b3fc03c3
Update http->https in license (#6945)
1. Update: http://www.php.net/license/3_01.txt to https, as there is anyway server header "Location:" to https.
2. Update few license 3.0 to 3.01 as 3.0 states "php 5.1.1, 4.1.1, and earlier".
3. In some license comments is "at through the world-wide-web" while most is without "at", so deleted.
4. fixed indentation in some files before |
2021-05-06 12:16:35 +02:00
Máté Kocsis
c6723728df
Generate ext/intl class entries from stubs
Closes GH-6670
2021-02-09 13:37:24 +01:00
Nikita Popov
27ad19c3e8 Validate collator earlier during sort
Check this once before the sort, instead of on every compare.
Also directly store the UCollator to make things more obvious.
2020-07-24 11:58:10 +02:00
Max Semenik
2b5de6f839
Remove proto comments from C files
Closes GH-5758
2020-07-06 21:13:34 +02:00
Christoph M. Becker
864fb0ec23 Implement #47074: phpinfo() reports "On" as 1 for the some extensions
What is modified as boolean, should also be displayed as boolean.
2020-06-04 11:25:45 +02:00
George Peter Banyard
ea8686540a Fix [-Wundef] warning in INTL extension 2020-05-20 18:22:10 +02:00
Máté Kocsis
f00bcfbb7d
Generate method entries for ext/intl
Closes GH-5370
2020-04-14 13:39:00 +02:00
Máté Kocsis
305b17e85f
Do not include the same stub multiple times
Closes GH-5322
2020-04-03 14:23:54 +02:00
Máté Kocsis
86780ff79f
Add stubs for NumberFormatter
Closes GH-4827
2020-02-09 22:10:12 +01:00
Máté Kocsis
c42572970a
Add various stubs for Intl
Closes GH-4826
2020-02-04 14:55:21 +01:00
Máté Kocsis
a827db24f1
Add stubs for IntlCalendar
Closes GH-4846
2020-02-04 14:50:02 +01:00
Máté Kocsis
fe7761b0ad
Add stubs for IntlDateFormatter & MessageFormatter
Closes GH-4812
2020-02-04 13:08:06 +01:00
Máté Kocsis
e08ce4c13d
Add stubs for various intl functions
Closes GH-4819
- Add stubs for idn functions
- Add stubs for grapheme functions
- Add stubs for Spoofchecker
- Add stubs for Normalizer
- Add stubs for ResourceBundle
- Fix arginfos
- Add support for union return types
- Fix arginfo for resourcebundle_create()
2020-01-03 18:54:57 +01:00
Fabien Villepinte
e2a8cc0114 Fix typo with msgfmt_parse_message() 2019-11-19 19:48:13 +01:00
Máté Kocsis
65db340ae7 Add stubs for the Locale component of Intl 2019-11-16 18:15:03 +01:00
Máté Kocsis
6d0366ad08 Add stubs for IntlTimeZone 2019-11-04 14:10:01 +01:00
Gabriel Caruso
5d6e923d46
Remove mention of PHP major version in Copyright headers
Closes GH-4732.
2019-09-25 14:51:43 +02:00
Peter Kokot
92ac598aab Remove local variables
This patch removes the so called local variables defined per
file basis for certain editors to properly show tab width, and
similar settings. These are mainly used by Vim and Emacs editors
yet with recent changes the once working definitions don't work
anymore in Vim without custom plugins or additional configuration.
Neither are these settings synced across the PHP code base.

A simpler and better approach is EditorConfig and fixing code
using some code style fixing tools in the future instead.

This patch also removes the so called modelines for Vim. Modelines
allow Vim editor specifically to set some editor configuration such as
syntax highlighting, indentation style and tab width to be set in the
first line or the last 5 lines per file basis. Since the php test
files have syntax highlighting already set in most editors properly and
EditorConfig takes care of the indentation settings, this patch removes
these as well for the Vim 6.0 and newer versions.

With the removal of local variables for certain editors such as
Emacs and Vim, the footer is also probably not needed anymore when
creating extensions using ext_skel.php script.

Additionally, Vim modelines for setting php syntax and some editor
settings has been removed from some *.phpt files.  All these are
mostly not relevant for phpt files neither work properly in the
middle of the file.
2019-02-03 21:03:00 +01:00
Christoph M. Becker
8a4c2f1621 Require ICU ≥ 50.1
Given that ICU is a set of lively developed libraries, that ICU 50.1
has been released on 2012-11-05, and PHP 7.4 is scheduled to be
released seven years after it, we consider it appropriate to ditch
these legacy versions.

Particularly, that would be a reasonable groundwork to implement part
two of the “Deprecate and remove INTL_IDNA_VARIANT_2003” RFC[1], namely
to default idn_to_ascii()'s and idn_to_utf8()'s $variant parameter to
INTL_IDNA_VARIANT_UTS46, which is not defined in ICU < 4.6.

See also the related discussion on internals@[2].

[1] <https://wiki.php.net/rfc/deprecate-and-remove-intl_idna_variant_2003>
[2] <http://news.php.net/php.internals/101626>ff
2018-09-15 13:59:54 +02:00
Peter Kokot
b1767d8a56 Bump intl extension version to PHP release version
This patch syncs and simplifies the intl core extension versioning
to match the PHP release version.
2018-06-14 23:35:29 +02:00
Anatol Belski
14de058086 Rethink conditions
Raise the requirement to ICU 56. Mixing both old and new normalizer APIs
would create too much complexity. Therefore go by the recommended ICU
version where all the normalizer API became stable. For the older ICU,
the deprecated normalizer API is used.
2018-04-06 21:33:13 +02:00
Anatol Belski
13a5020f98 Check feature availability as ICU < 49 is still supported 2018-04-05 18:08:49 +02:00
Paul Crovella
b873d3c288
Add normalizer_get_raw_decomposition function
Implements #76111 https://bugs.php.net/bug.php?id=76111
2018-03-22 23:27:39 +01:00
Dmitry Stogov
9e709e2fa0 Move constants into read-only data segment 2017-12-14 18:43:44 +03:00
Anatol Belski
ff1b1c2761 Add TZ and Unicode versions to intl MINFO 2017-10-21 16:17:31 +02:00
Sara Golemon
80f4297c25 Merge branch 'PHP-7.0' into PHP-7.1
* PHP-7.0:
  Bugfix #74993 Wrong reflection param into for some intl: lookup_*() methods
2017-07-26 18:55:46 -04:00
Sara Golemon
c7aa8ba0ee
Bugfix #74993 Wrong reflection param into for some intl: lookup_*() methods 2017-07-26 18:55:23 -04:00
Remi Collet
90f33b1ac7 Merge branch 'PHP-7.0' into PHP-7.1
* PHP-7.0:
  NEWS
  Fix bug #74705 for collator_get_sort_key
  Fixes bug #74705 Wrong ReflectionInfo for Collator::getSortKey()
2017-06-13 08:50:10 +02:00
Remi Collet
78970d5338 Fix bug #74705 for collator_get_sort_key 2017-06-13 08:48:17 +02:00
Joe Watkins
2735318c7b
Merge branch 'PHP-7.0' into PHP-7.1
* PHP-7.0:
  Fix bug #74468 wrong reflection on Collator::sortWithSortKeys
2017-05-02 06:21:54 +01:00
Fabien Villepinte
f50df1d0e3
Fix bug #74468 wrong reflection on Collator::sortWithSortKeys 2017-05-02 06:20:40 +01:00
Anatol Belski
35bbcd17a9 remove unused declarations 2016-06-23 15:02:43 +02:00
Nikita Popov
1ac152938c Move semicolon into TSRMLS_CACHE_EXTERN/DEFINE
Also re bug #71575.
2016-03-03 16:50:01 +01:00