php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Doc Bug #75339 IntlChar::chr - typo in the output example
Submitted: 2017-10-08 15:55 UTC Modified: 2017-10-09 14:11 UTC
From: fabien dot villepinte at gmail dot com Assigned: cmb (profile)
Status: Closed Package: intl (PECL)
PHP Version: Irrelevant OS:
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
MUST BE VALID
Solve the problem:
26 - 25 = ?
Subscribe to this entry?

 
 [2017-10-08 15:55 UTC] fabien dot villepinte at gmail dot com
Description:
------------
http://php.net/manual/en/intlchar.chr.php
There is a typo in the output example.
The 2nd line should be 'string(1) "?"' instead of 'string(1) "A"'.

https://3v4l.org/ggakS

Test script:
---------------
<?php
$values = ["A", 63, 123, 9731];
foreach ($values as $value) {
    var_dump(IntlChar::chr($value));
}

Expected result:
----------------
string(1) "A"
string(1) "?"
string(1) "{"
string(3) "☃"

Actual result:
--------------
string(1) "A"
string(1) "A"
string(1) "{"
string(3) "☃"

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2017-10-09 13:36 UTC] cmb@php.net
-Status: Open +Status: Verified -Assigned To: +Assigned To: cmb
 [2017-10-09 14:10 UTC] cmb@php.net
Automatic comment from SVN on behalf of cmb
Revision: http://svn.php.net/viewvc/?view=revision&amp;revision=343219
Log: Fix #75339: IntlChar::chr - typo in the output example
 [2017-10-09 14:11 UTC] cmb@php.net
-Status: Verified +Status: Closed
 [2017-10-09 14:11 UTC] cmb@php.net
This bug has been fixed in the documentation's XML sources. Since the
online and downloadable versions of the documentation need some time
to get updated, we would like to ask you to be a bit patient.

Thank you for the report, and for helping us make our documentation better.
 [2020-02-07 06:06 UTC] phpdocbot@php.net
Automatic comment on behalf of cmb
Revision: http://git.php.net/?p=doc/en.git;a=commit;h=3df3d7e640099ce110e02a94f7448a9f128428ee
Log: Fix #75339: IntlChar::chr - typo in the output example
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Mar 29 01:01:28 2024 UTC