Skip to content

Commit 5d6d1cc

Browse files
ext/intl: Add #[\Deprecated] to U_MULTIPLE_DECIMAL_SEPERATORS constant
1 parent d6d0a2a commit 5d6d1cc

File tree

4 files changed

+30
-3
lines changed

4 files changed

+30
-3
lines changed

ext/intl/common/common.stub.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -425,9 +425,9 @@
425425
/**
426426
* Typo: kept for backward compatibility. Use U_MULTIPLE_DECIMAL_SEPARATORS
427427
* @var int
428-
* @deprecated
429428
* @cvalue U_MULTIPLE_DECIMAL_SEPERATORS
430429
*/
430+
#[\Deprecated(since: '8.3', message: 'use U_MULTIPLE_DECIMAL_SEPARATORS instead')]
431431
const U_MULTIPLE_DECIMAL_SEPERATORS = UNKNOWN;
432432
/**
433433
* @var int

ext/intl/common/common_arginfo.h

Lines changed: 10 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

ext/intl/common/common_enum.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,10 @@
2121
// Fix build on Windows/old versions of ICU
2222
#include <stdio.h>
2323

24+
extern "C" {
25+
#include <zend_attributes.h>
26+
}
27+
2428
#include "common_enum.h"
2529
#include "common_arginfo.h"
2630

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
--TEST--
2+
U_MULTIPLE_DECIMAL_SEPERATORS is deprecated
3+
--EXTENSIONS--
4+
intl
5+
--FILE--
6+
<?php
7+
var_dump(U_MULTIPLE_DECIMAL_SEPERATORS);
8+
var_dump(constant('U_MULTIPLE_DECIMAL_SEPERATORS'));
9+
?>
10+
--EXPECTF--
11+
Deprecated: Constant U_MULTIPLE_DECIMAL_SEPERATORS is deprecated since 8.3, use U_MULTIPLE_DECIMAL_SEPARATORS instead in %s on line %d
12+
int(65793)
13+
14+
Deprecated: Constant U_MULTIPLE_DECIMAL_SEPERATORS is deprecated since 8.3, use U_MULTIPLE_DECIMAL_SEPARATORS instead in %s on line %d
15+
int(65793)

0 commit comments

Comments
 (0)