Bug #78002 [NEW]: APCUIterator regexp array returns no results

From: Date: Sat, 11 May 2019 10:50:50 +0000
Subject: Bug #78002 [NEW]: APCUIterator regexp array returns no results
Groups: php.bugs 
Request: Send a blank email to php-bugs+get-220814@lists.php.net to get a copy of this message
From:             ariartwt at gmail dot com
Operating system: Ubuntu 18.04.2
PHP version:      7.2.18
Package:          Unknown/Other Function
Bug Type:         Bug
Bug description:APCUIterator regexp array returns no results

Description:
------------
---
From manual page: https://php.net/apcuiterator.construct
---

Passing in an array of PCRE regular expressions to the constructor of
APCUIterator as first argument never return any result.

Test script:
---------------
<?php 

apcu_add("Test","data");

echo (new APCUIterator("/^Test$/"))->getTotalCount();// 1
echo (new APCUIterator(["Test"]))->getTotalCount();// 1
echo (new APCUIterator(["/^Test$/"]))->getTotalCount();// 0 -> should be
1


Expected result:
----------------
In my understanding of the documentation, we should be able to pass as
first argument an array filled with regexp to find matching entries in
apcu's stored keys.


-- 
Edit bug report at https://bugs.php.net/bug.php?id=78002&edit=1
-- 
Try a snapshot (PHP 5.4):   https://bugs.php.net/fix.php?id=78002&r=trysnapshot54
Try a snapshot (PHP 5.5):   https://bugs.php.net/fix.php?id=78002&r=trysnapshot55
Try a snapshot (trunk):     https://bugs.php.net/fix.php?id=78002&r=trysnapshottrunk
Fixed in SVN:               https://bugs.php.net/fix.php?id=78002&r=fixed
Fixed in release:           https://bugs.php.net/fix.php?id=78002&r=alreadyfixed
Need backtrace:             https://bugs.php.net/fix.php?id=78002&r=needtrace
Need Reproduce Script:      https://bugs.php.net/fix.php?id=78002&r=needscript
Try newer version:          https://bugs.php.net/fix.php?id=78002&r=oldversion
Not developer issue:        https://bugs.php.net/fix.php?id=78002&r=support
Expected behavior:          https://bugs.php.net/fix.php?id=78002&r=notwrong
Not enough info:            https://bugs.php.net/fix.php?id=78002&r=notenoughinfo
Submitted twice:            https://bugs.php.net/fix.php?id=78002&r=submittedtwice
register_globals:           https://bugs.php.net/fix.php?id=78002&r=globals
PHP 4 support discontinued: https://bugs.php.net/fix.php?id=78002&r=php4
Daylight Savings:           https://bugs.php.net/fix.php?id=78002&r=dst
IIS Stability:              https://bugs.php.net/fix.php?id=78002&r=isapi
Install GNU Sed:            https://bugs.php.net/fix.php?id=78002&r=gnused
Floating point limitations: https://bugs.php.net/fix.php?id=78002&r=float
No Zend Extensions:         https://bugs.php.net/fix.php?id=78002&r=nozend
MySQL Configuration Error:  https://bugs.php.net/fix.php?id=78002&r=mysqlcfg



Thread (4 messages)

« previous php.bugs (#220814) next »