Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:127601 X-Original-To: internals@lists.php.net Delivered-To: internals@lists.php.net Received: from php-smtp4.php.net (php-smtp4.php.net [45.112.84.5]) by lists.php.net (Postfix) with ESMTPS id 6CE0B1A00BC for ; Thu, 5 Jun 2025 01:04:19 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=php.net; s=mail; t=1749085335; bh=gaGT4jQ6pmv+amIE/oMaDEzQpmP3xQe7+2CKGqz/LKo=; h=From:Date:Subject:To:From; b=N6mEQv76na8rWRPHmDal6Rzu5Nm+10ZfGA24hKAlue5X7ZY6CPVo037bsPHk4ZDdt ZFQ78yn2Eu0LNzWVbEqyn4L/Twpc/7f8HF55WyNj8spl7nahUMYxg3ZOW/88ttITao ggmlnhGG9gRwPvPT3HyhO/jvCkWxNtzjN/OABQZnmX+XRRKu7P6SaEplhsDIeb3qkq urfl6vgGqUMxum7Iwg+y64KjgZxsOPpmoM+hHhb0tlprfDU/WNGrQRhnk2ZeIYrMZ3 xYR04umezuvwv8QDaq8NnLy4XmT0EuZtbAuB2W/yVFuDRexyd1mY1s2BhSzpUE8TJU 8H/PnvfpUf1jg== Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id B45121801D5 for ; Thu, 5 Jun 2025 01:02:13 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-25) on php-smtp4.php.net X-Spam-Level: X-Spam-Status: No, score=-1.2 required=5.0 tests=BAYES_40,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,DMARC_PASS,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=4.0.1 X-Spam-Virus: Error (Cannot connect to unix socket '/var/run/clamav/clamd.ctl': connect: Connection refused) X-Envelope-From: Received: from mail-wr1-f51.google.com (mail-wr1-f51.google.com [209.85.221.51]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by php-smtp4.php.net (Postfix) with ESMTPS for ; Thu, 5 Jun 2025 01:02:10 +0000 (UTC) Received: by mail-wr1-f51.google.com with SMTP id ffacd0b85a97d-3a4f72cba73so1188883f8f.1 for ; Wed, 04 Jun 2025 18:04:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1749085453; x=1749690253; darn=lists.php.net; h=to:subject:message-id:date:from:mime-version:from:to:cc:subject :date:message-id:reply-to; bh=ZMgQaCDU5NWTb0WFiNwnHQmI1kSTqQfz8ZuvcDfHuzk=; b=XGaaaeLd0HWIsPwZutIHuyqqAs3S3e5/hg5kK81PSxqr+rK1L2pCNUXKadXZuXQm1s 3fHTAJ9D2quECeL2SRzF/sW4U5s83QG75c/RHvOuxtOiGKGMMRigFVEHHDpP47gSCN/2 j8RFtce9hs+k1qzTgoKccdme1fSDKf2boza7GYA9heafxCgHdRvPbr6D7qsnSYERMNzr P88qvXKaZ5txNlNTysSJpVUDheq0QUmUOg24kFphgZvhUF7tPKv8CP3y1KDkblrP3QN2 7Lh4PZgKQR3CniNNAQTm1MzS3RySLYEnvexI9kcQanFr/oYvKEiMmrsvmI2Hnx2p+bp0 nmLQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1749085453; x=1749690253; h=to:subject:message-id:date:from:mime-version:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=ZMgQaCDU5NWTb0WFiNwnHQmI1kSTqQfz8ZuvcDfHuzk=; b=T4wxXRQeoTPQJG6A0845nUHJlwBCIkOUdUNPRQF498eKY7qAfDeeK/N559k9CHwUbA F4Qkr4+XbYoPWXM8vOpzZqLM9jyVNxlk909wa8UcpAxzLPOsv+4PdtzEcj7LToVl6VY1 270jEajBFk+06gn3F6993o4v+EKPxsXE9lhsNVrHQfycanLqekpu99+pC2oho7Z9qjhy vZTRihAGMtF4YkGc/KLdnR33lfohYz/i/WokPPWsZtg7nh3dwmntLmKAaeg7uo9cHgvR qxS8PAtWA3e5DrmSpfqMwr0fjLi4GooKvxKa7YgMRWyWaUaDqbJQxZ+TgLmY7XaY8aRY 4jrQ== X-Gm-Message-State: AOJu0Yy07LL/Zx33AILnwPAhvHriEzjG28QQrBor1WYPJ6KvYh0uUdOp W289gGW9OrM6BEfolges+1OAYVBTptxbKvaszt8im6SbF8MlTtIIje2jMvzQWnH85iw95kQJAsS 4aDRQWzhX1qIcdkIGk+A6N0i86HNclMp/DrmmgQ== X-Gm-Gg: ASbGnctZHFUQ5Z6wGNvFQGgTjeE6prz22/4de1zbl0JXxv/3zw15oZCkenSTwjpFlgT YN+AHAVIhaowR1xvzABw+RCEPF+ipM3zxKWcbTW6pp3YbJL4cK3DEP+mGycqEM5uVt0mUWF4B/q Hmsazlvee8g+yg6OAHfEFvH/L51ilEHvo= X-Google-Smtp-Source: AGHT+IFbFxf3bS5f4S7E1WOTHDyE85/GsZzgi0C5N/wDptKue3GIQv9zz4WQ3b2OggosBeTCpJDDLHic02Phmuw9z3Q= X-Received: by 2002:a05:6000:310d:b0:3a4:dc80:b907 with SMTP id ffacd0b85a97d-3a526e1ecdamr1280341f8f.26.1749085452684; Wed, 04 Jun 2025 18:04:12 -0700 (PDT) Precedence: bulk list-help: list-post: List-Id: internals.lists.php.net x-ms-reactions: disallow MIME-Version: 1.0 Date: Thu, 5 Jun 2025 10:04:00 +0900 X-Gm-Features: AX0GCFvxofsr9DBrFOscYDn9rlOwUDTSWeskkFB9UNs3cICfl_5Man8bRZKkXKY Message-ID: Subject: [PHP-DEV][DISCUSSION] grapheme_* functions adds locale in parameter (or any?) To: php internals Content-Type: text/plain; charset="UTF-8" From: youkidearitai@gmail.com (youkidearitai) Hi, Internals I would like adds locale parameter that already there are grapheme_* functions. Because Unicode is locale-dependency but grapheme_* functions is not locale-dependency. For example, Add $locale parameter is below. ``` grapheme_extract( string $haystack, int $size, int $type = GRAPHEME_EXTR_COUNT, int $offset = 0, int &$next = null, string ?$locale = null ): string|false grapheme_str_split(string $string, int $length = 1, string ?$locale = null): array|false grapheme_stripos(string $haystack, string $needle, int $offset = 0, string ?$locale = null): int|false grapheme_stristr(string $haystack, string $needle, bool $beforeNeedle = false, string ?$locale = null): string|false grapheme_strlen(string $string, ?string $locale = null): int|false|null grapheme_strpos(string $haystack, string $needle, int $offset = 0, string ?$locale = null): int|false grapheme_strripos(string $haystack, string $needle, int $offset = 0, string ?$locale = null): int|false grapheme_strrpos(string $haystack, string $needle, int $offset = 0, string ?$locale = null): int|false grapheme_strstr(string $haystack, string $needle, bool $beforeNeedle = false, ?$locale = null): string|false grapheme_substr(string $string, int $offset, ?int $length = null, ?string ?$locale = null): string|false ``` What do you think? I would like go to write an RFC if this is fine. Regards Yuya -- --------------------------- Yuya Hamada (tekimen) - https://tekitoh-memdhoi.info - https://github.com/youkidearitai -----------------------------