aboutsummaryrefslogtreecommitdiffhomepage
path: root/crates/shirabe/src/util/perforce.rs
diff options
context:
space:
mode:
authornsfisis <nsfisis@gmail.com>2026-06-20 00:31:45 +0900
committernsfisis <nsfisis@gmail.com>2026-06-20 00:31:49 +0900
commitcac18ef73a39b4ac41fa4d6ccb753804d4c42cb7 (patch)
tree968f438437042e8092752aa521c2d7e6ae28307e /crates/shirabe/src/util/perforce.rs
parent7c5162e7c2f9d466e96248b7482aa98350244e8b (diff)
downloadphp-shirabe-cac18ef73a39b4ac41fa4d6ccb753804d4c42cb7.tar.gz
php-shirabe-cac18ef73a39b4ac41fa4d6ccb753804d4c42cb7.tar.zst
php-shirabe-cac18ef73a39b4ac41fa4d6ccb753804d4c42cb7.zip
feat(php-shim): implement count()
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Diffstat (limited to 'crates/shirabe/src/util/perforce.rs')
-rw-r--r--crates/shirabe/src/util/perforce.rs8
1 files changed, 1 insertions, 7 deletions
diff --git a/crates/shirabe/src/util/perforce.rs b/crates/shirabe/src/util/perforce.rs
index 1f64dcc..937e305 100644
--- a/crates/shirabe/src/util/perforce.rs
+++ b/crates/shirabe/src/util/perforce.rs
@@ -682,13 +682,7 @@ impl Perforce {
let res_array = explode(PHP_EOL, &result);
for line in &res_array {
let res_bits = explode(" ", line);
- if count(&PhpMixed::List(
- res_bits
- .iter()
- .map(|s| Box::new(PhpMixed::String(s.clone())))
- .collect(),
- )) > 4
- {
+ if res_bits.len() > 4 {
let branch = Preg::replace(
r"/[^A-Za-z0-9 ]/",
"",