php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Doc Bug #71496 mb_ereg & mb_eregi definitions are missing & symbol on $regs parameter
Submitted: 2016-02-02 05:53 UTC Modified: 2016-02-03 18:52 UTC
From: cbot at epu dot ntua dot gr Assigned: cmb (profile)
Status: Closed Package: mbstring related
PHP Version: Irrelevant OS:
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: cbot at epu dot ntua dot gr
New email:
PHP Version: OS:

 

 [2016-02-02 05:53 UTC] cbot at epu dot ntua dot gr
Description:
------------
---
From manual page: http://www.php.net/function.mb-ereg

From manual page: http://www.php.net/function.mb-eregi
---

Both mb_ereg and mb_eregi functions have an optional $regs parameter which will be returned as an array. Since this is a pass-by-reference parameter, shouldn't the definitions mention it with the & (ampersand) symbol?

IDEs, using stubs based on the documentation, complain for undefined variable.



Expected result:
----------------
int mb_ereg ( string $pattern , string $string [, array &$regs ] )
int mb_eregi ( string $pattern , string $string [, array &$regs ] )

Actual result:
--------------
int mb_ereg ( string $pattern , string $string [, array $regs ] )
int mb_eregi ( string $pattern , string $string [, array $regs ] )

Patches

bug71496_mb-ereg (last revision 2016-02-02 06:36 UTC by cbot at epu dot ntua dot gr)
bug71496_mb-eregi (last revision 2016-02-02 06:34 UTC by cbot at epu dot ntua dot gr)

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2016-02-03 18:51 UTC] cmb@php.net
Automatic comment from SVN on behalf of cmb
Revision: http://svn.php.net/viewvc/?view=revision&revision=338566
Log: fixed #71496: mb_ereg & mb_eregi definitions are missing & symbol on $regs parameter
 [2016-02-03 18:52 UTC] cmb@php.net
-Status: Open +Status: Closed -Assigned To: +Assigned To: cmb
 [2016-02-03 18:52 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:07 UTC] phpdocbot@php.net
Automatic comment on behalf of cmb
Revision: http://git.php.net/?p=doc/en.git;a=commit;h=0245c2d9fad1e11f9b19520d34eb612a4c9fa753
Log: fixed #71496: mb_ereg & mb_eregi definitions are missing & symbol on $regs parameter
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Tue Apr 23 08:01:30 2024 UTC