Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:119480 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 62398 invoked from network); 7 Feb 2023 16:21:53 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 7 Feb 2023 16:21:53 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 7F32618033A for ; Tue, 7 Feb 2023 08:21:52 -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.7 required=5.0 tests=BAYES_05,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,NICE_REPLY_A, 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-wm1-f42.google.com (mail-wm1-f42.google.com [209.85.128.42]) (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, 7 Feb 2023 08:21:52 -0800 (PST) Received: by mail-wm1-f42.google.com with SMTP id k8-20020a05600c1c8800b003dc57ea0dfeso13590593wms.0 for ; Tue, 07 Feb 2023 08:21:51 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:in-reply-to:from:references:to :content-language:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=f5LKZeJ81lEhOjhsJyfyJYcOWC3C4HhjTAeNbJa07BM=; b=SwqUdRgoS7UeJfRJbeQrzAnW9KNdtF3dMH40vxyubN7UwmJR8JQzslaYFCKb/bw6Ev Nlp966cNLykKxnX4SH2bcqAeQOJAY2YUbKszylRfTTOSKush1fseCjw9d9/VvN7QojYs Bogfme3UN89rwVDa+HCTcTWxjPoyEJYJNy7gXEg2Vu8FLJRKBPlWfocN7/l5/UhPMGOj Ih7aumHNjX4L1Ub8w77PBU49f/i1qmjfWoHD4rcu+bOGQJwiBnHxUR7y+eKWETUNCLMT 1WgTd138vUJ3a3U29WzWQ5yoyD8vmi+FYzmlW7Mtx6pD62aafctKSM/Brcw7Yo3Km+Yr d/kQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:in-reply-to:from:references:to :content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=f5LKZeJ81lEhOjhsJyfyJYcOWC3C4HhjTAeNbJa07BM=; b=mKgKc9UTDeHKEusnhtvGmnU6kOG6MBvaHnWEpEV1HhnzIdOl8kVed94jQOxluUIQ8A CQVFPI75NkbO+TljQLD62Vb32STj2Y5Z5ag4I3fKkrtJTSMt8ELfNG5t/Ym2ROSNrl/l vvANPje7TbfhPFOWnFmLY4/BdSCjMBgbLfhg8ppuLWoPEgMltS+1Gbr8GNxHH6k4tzZt o1Qf6nAWKsLcNugpKhDVUiRilHYVOgeq7JFQXoP2HWUByWIPDaisJnl3ZbtYNRpDojiG 72rJ7HUcicxKcAOV6E37oUVINM+aPUmdTulD+TV2THlCrIH/PHiOz2veUmILLcMMNRQ0 TiKQ== X-Gm-Message-State: AO0yUKW5ASMB+UctPw+To6N39cptzNVNFGG4iQmP1c+aD8dop7j+r0Fl DIfVZ2Rae8jdLmQJxDapyAGsuKMXSUQ= X-Google-Smtp-Source: AK7set+L6Yw5qAYEJnIEzC0gKX6hGHRVGnH9O26lVZcDzUsjdsDyQr+4MFcf9F4+yd+AFhR0gAttBQ== X-Received: by 2002:a05:600c:1894:b0:3de:1d31:1048 with SMTP id x20-20020a05600c189400b003de1d311048mr3653605wmp.29.1675786910815; Tue, 07 Feb 2023 08:21:50 -0800 (PST) Received: from [192.168.0.22] (cpc104104-brig22-2-0-cust548.3-3.cable.virginm.net. [82.10.58.37]) by smtp.googlemail.com with ESMTPSA id j14-20020a05600c190e00b003daf681d05dsm15646428wmq.26.2023.02.07.08.21.50 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 07 Feb 2023 08:21:50 -0800 (PST) Message-ID: <5edaa45e-08ff-9529-3a1b-42f655a68497@gmail.com> Date: Tue, 7 Feb 2023 16:21:49 +0000 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101 Thunderbird/102.6.1 Content-Language: en-GB To: PHP Internals References: <18627e9c82d.1185ba82a2669697.6762525826203739336@wendelladriel.com> <8c3fb742-4367-0e4a-b96e-142657ac902c@gmail.com> In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Subject: Re: [PHP-DEV] RFC Proposal - Types for Inline Variables From: rowan.collins@gmail.com (Rowan Tommins) On 07/02/2023 14:07, Olle Härstedt wrote: > It should perhaps be mentioned that analyzers can use type annotations > during their process, instead of the more clunky /** @var string */ or > similar you have to use today for local variables. This sounds like you're reaching for Python's approach, where the language "supports" the type annotation syntax, but doesn't actually do anything with it. I explained in another thread why I think that is a poor compromise, because it's unclear whether you can actually trust the annotations. The current "clunky" syntax is clearly a comment as far as the language itself is concerned, so there is no expectation when reading it that it will have a meaning to plain PHP. Regards, -- Rowan Tommins [IMSoP]