#48011 [NEW]: levenshtein second variant fails

From: Date: Sat, 18 Apr 2009 10:22:24 +0000
Subject: #48011 [NEW]: levenshtein second variant fails
Groups: php.bugs 
Request: Send a blank email to php-bugs+get-135946@lists.php.net to get a copy of this message
From: joris at bonboa dot com Operating system: Mac OS X PHP version: 5.2.9 PHP Bug Type: Unknown/Other Function Bug description: levenshtein second variant fails Description: ------------ Does de second variant of the levenshtein function actuall work? The second output line I dig, but not the first. Any idea? Reproduce code: --------------- --- From manual page: function.levenshtein --- $i=0; $u=0; $d=0; $t1='Joris'; $t2='oris'; $l=levenshtein($t1,$t2,$i,$u,$d); echo $t1.'='.$t2.' '.$l.':'.$i.':'.$u.':'.$d."\n"; $l=levenshtein($t1,$t2); echo $t1.'='.$t2.' '.$l."\n"; Expected result: ---------------- Joris=oris 1:0:0:1 Joris=oris 1 Actual result: -------------- Joris=oris 0:0:0:0 Joris=oris 1 -- Edit bug report at http://bugs.php.net/?id=48011&edit=1 -- Try a CVS snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=48011&r=trysnapshot52 Try a CVS snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=48011&r=trysnapshot53 Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=48011&r=trysnapshot60 Fixed in CVS: http://bugs.php.net/fix.php?id=48011&r=fixedcvs Fixed in CVS and need be documented: http://bugs.php.net/fix.php?id=48011&r=needdocs Fixed in release: http://bugs.php.net/fix.php?id=48011&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=48011&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=48011&r=needscript Try newer version: http://bugs.php.net/fix.php?id=48011&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=48011&r=support Expected behavior: http://bugs.php.net/fix.php?id=48011&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=48011&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=48011&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=48011&r=globals PHP 4 support discontinued: http://bugs.php.net/fix.php?id=48011&r=php4 Daylight Savings: http://bugs.php.net/fix.php?id=48011&r=dst IIS Stability: http://bugs.php.net/fix.php?id=48011&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=48011&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=48011&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=48011&r=nozend MySQL Configuration Error: http://bugs.php.net/fix.php?id=48011&r=mysqlcfg

« previous php.bugs (#135946) next »