Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:119555 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 28619 invoked from network); 15 Feb 2023 05:18:55 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 15 Feb 2023 05:18:55 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 4CD45180210 for ; Tue, 14 Feb 2023 21:18:54 -0800 (PST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on php-smtp4.php.net X-Spam-Level: X-Spam-Status: No, score=-0.2 required=5.0 tests=BAYES_20,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.2 X-Spam-ASN: AS15169 209.85.128.0/17 X-Spam-Virus: No X-Envelope-From: Received: from mail-wr1-f43.google.com (mail-wr1-f43.google.com [209.85.221.43]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by php-smtp4.php.net (Postfix) with ESMTPS for ; Tue, 14 Feb 2023 21:18:53 -0800 (PST) Received: by mail-wr1-f43.google.com with SMTP id co8so14106651wrb.1 for ; Tue, 14 Feb 2023 21:18:53 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:message-id:references :in-reply-to:user-agent:subject:to:from:date:from:to:cc:subject:date :message-id:reply-to; bh=6kyQdvguflUV80+GXKnpajAfwEZsYUHV4mWW2IDpdRM=; b=WpuvN3LODJoby1HU4uQsOknIHIalbCMJRBCkCfOhXA0hAk8Mi/JhaN9kCFftIMRS29 jrAskh6/v1VF84OcMdTjxBVdig/CaprNxrjPM0+sfdqJ+9F1D8o6jPTx0t1slwFsL4je PVwDMmkW4yLYl958dI8N/aQEydM2hFUho970I/XVhzjuVKeuaQ5tNXJfKHnooPQOrtgy ZnveG+WtJOQiwqx2evMI0kkfEZaS2q2nklSM2xUVNYM85EDO77tFvR42LsPQozrwISPi buYbNsOpAnEqKQmZFWEXbL5biXcR6u4jTsGyRn7HUzQuxKzJ+NRzJNXmfQbna5u5Il1G gu5g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:message-id:references :in-reply-to:user-agent:subject:to:from:date:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=6kyQdvguflUV80+GXKnpajAfwEZsYUHV4mWW2IDpdRM=; b=YbNLyTysIPsr/7w1b8dzCfO139boeemYx/XxnY1ihVqfIoAquELLhnuMDacVKCEwqW v8BHmKz7xl4v/bVDDEWbVkkMe5V70JeEtp/CtcdF/k6q3jNv5cfSR07ukwZ2XufBOAdl t8g+NIMnwuqHAR1e7cfGSTh0k8DARYy62GtdhYdq0MsETkbeDFvAKMeZ1Lyt9db33evK TO7ibwFd+klmYbsB7ruoZEcfyfnJv0B62JzXja5IdMN5q2J2jPJTLJa6eRCP/hzNAaf/ iNM/60pDcCCd/Wx/V2BQnMcn6aYcq6wdA2Ig3h+1J7fsvGAVfX6a/qtI78FBzNQpZRrx nPhw== X-Gm-Message-State: AO0yUKUuxkbVXGbm+TW9nY1spjXe/HS0/NXtomX7DaO73YDH7qbu0eCM mBmEWYm4Jkt/Pa9DnF3tOoZPLmFnc2s= X-Google-Smtp-Source: AK7set+m/hM/fsAzmwP+ADj/H13QkZzJtDw6Z9/gzee8txeXoF1PbAx8L7XoCZ1cSsACIwGwZacVcQ== X-Received: by 2002:a5d:4284:0:b0:2c5:594d:d9f7 with SMTP id k4-20020a5d4284000000b002c5594dd9f7mr423099wrq.63.1676438332610; Tue, 14 Feb 2023 21:18:52 -0800 (PST) Received: from [127.0.0.1] (cpc83311-brig21-2-0-cust191.3-3.cable.virginm.net. [86.20.40.192]) by smtp.gmail.com with ESMTPSA id q4-20020a05600000c400b002c54737e908sm12772330wrx.91.2023.02.14.21.18.51 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 14 Feb 2023 21:18:51 -0800 (PST) Date: Wed, 15 Feb 2023 05:18:50 +0000 To: internals@lists.php.net User-Agent: K-9 Mail for Android In-Reply-To: <7e86a2d2-b971-592c-64e3-e86c13b5be80@cubiclesoft.com> References: <92c4514f-70e3-75c9-7084-9e29641e25e7@gmail.com> <7e86a2d2-b971-592c-64e3-e86c13b5be80@cubiclesoft.com> Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Subject: Re: [PHP-DEV] [RFC] Working With Substrings From: rowan.collins@gmail.com (Rowan Tommins) On 15 February 2023 02:35:42 GMT, Thomas Hruska = wrote: >On 2/14/2023 2:02 PM, Rowan Tommins wrote: >I thought about that but didn't know how well it would be received nor, p= erhaps more importantly, the direction it should take (i=2Ee=2E a formal Ze= nd type in the engine, extending the existing zend_string type, a class, so= me combination, or something else entirely)=2E All of the more advanced op= tions I came up with would have required some code changes to the PHP sourc= e itself with a new data type being the most involved and probably the most= controversial=2E My instinct was that it could just be a built-in class, with an internal p= ointer to a zend_string that's completely invisible to userland=2E Somethin= g like how the SimpleXML and DOM objects just point into a libxml parse res= ult=2E Then to add to existing functions requires changing an argument type from = string to string|Buffer, rather than adding new arguments=2E=20 No change to the type system needed, internally or externally, just some c= ode to unwrap the pointer=2E But perhaps I'm being naive and oversimplifyin= g, as I don't have a deep understanding of the engine=2E >I'm not entirely sure what the next step here should be=2E Should I go r= esearch the above, or go back and develop/test and then propose something c= oncrete in an OO direction and gather feedback at that point, or should we = hash it out a bit more here on the list to get a more specific direction to= go in? Well, those were just my thoughts; maybe someone else will come along shor= tly with a very different take=2E Regards, --=20 Rowan Tommins [IMSoP]