php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Request #34835 levenshtein with 3 parameters does not work as expected
Submitted: 2005-10-12 10:08 UTC Modified: 2021-01-01 16:15 UTC
Votes:1
Avg. Score:5.0 ± 0.0
Reproduced:1 of 1 (100.0%)
Same Version:0 (0.0%)
Same OS:1 (100.0%)
From: fdcxl at 163 dot com Assigned: cmb (profile)
Status: Wont fix Package: Strings related
PHP Version: 5.0.5 OS: Linux
Private report: No CVE-ID: None
View Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
If you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: fdcxl at 163 dot com
New email:
PHP Version: OS:

 

 [2005-10-12 10:08 UTC] fdcxl at 163 dot com
Description:
------------
levenshtein with 3 parameters does not work.
I have checked the soucecode, it treat the third parameter to be a callback function. While in the manual, it's supposed to be an integer.

Reproduce code:
---------------
levenshtein("abc", "abcd", 2);

Expected result:
----------------
2

Actual result:
--------------
Some warning message

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2005-10-12 10:13 UTC] tony2001@php.net
And the warning is: "Warning: levenshtein(): The general Levenshtein support is not there yet".
Reclassified as feature request.
 [2016-12-30 23:11 UTC] cmb@php.net
-Package: Feature/Change Request +Package: Strings related
 [2021-01-01 16:15 UTC] cmb@php.net
-Status: Open +Status: Wont fix -Assigned To: +Assigned To: cmb
 [2021-01-01 16:15 UTC] cmb@php.net
Support for callback parameters is completely removed as of PHP
8.0.0.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Tue Nov 12 03:01:29 2024 UTC