Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:123377 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 qa.php.net (Postfix) with ESMTPS id 0F9F51A009C for ; Tue, 21 May 2024 01:59:57 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=php.net; s=mail; t=1716256852; bh=QHimJ2yACBRoql0NuAYQTa9tok8TerFP9Za4I2h0x2A=; h=References:In-Reply-To:From:Date:Subject:To:From; b=TGpWUQZkbXNS54H5oUqrDQjLxqmv4rszqjdq3t5o4DhQ7tKeWKgYKBr8JqYg53wqr 6R2cfGGSJruHHqN1kE8rKs3q8YPLRDt2Nbdp/ziPW2utNr4B0EW1fwzRvOIAF6dQ6u L23y/HNPYFWYXL9GEmulzr1HH8ISjzfb36XJM8K6QGXEiMuLvt4cL24PvmmXeOleTz AFXGRy7ErKLAoNZ1EKoFlBUDMkrO6sJA8jEvVDVKV7XXeTGl4Op84SUMs9g3xcpqHY FCOlHAbi7nrkb5bwq9gdBtKKGJ5XgUl5sLFXG1z+RDpPPybLl0jaS4CEg/Vm+jZdo2 Vw3cKcKSY0poA== Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 3585818005D for ; Tue, 21 May 2024 02:00:50 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 4.0.0 (2022-12-13) on php-smtp4.php.net X-Spam-Level: X-Spam-Status: No, score=0.6 required=5.0 tests=BAYES_50,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,DMARC_PASS,FREEMAIL_FROM, HTML_MESSAGE,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=4.0.0 X-Spam-Virus: Error (Cannot connect to unix socket '/var/run/clamav/clamd.ctl': connect: Connection refused) X-Envelope-From: Received: from mail-vk1-f173.google.com (mail-vk1-f173.google.com [209.85.221.173]) (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 ; Tue, 21 May 2024 02:00:49 +0000 (UTC) Received: by mail-vk1-f173.google.com with SMTP id 71dfb90a1353d-4df9b81502eso1674959e0c.2 for ; Mon, 20 May 2024 18:59:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1716256793; x=1716861593; darn=lists.php.net; h=to:subject:message-id:date:from:in-reply-to:references:mime-version :from:to:cc:subject:date:message-id:reply-to; bh=lHOU4pHYUCLeDuzhTNeHmX2grAPufVZQZ/3Z8LT3BEw=; b=gCa2lYRzv6aMTtoErMkfcXKFL/iJDJxLyLOThcZf3ygtNN6bAAcJ7J/Y0iwF2rhQAW zvv2anB7n9E+3UqLEK1MCu66gSS6Ylie4UqsxeY7PNjcAgNWeewgkxpvFE09lmvgxB+H I4LM3vJIFGTH4xlGsHiytYLk5oyklomtPpxHt+shnd4tZjw6GCi82ApK4T4igiciJzVP /S6bcgJNxbVLiobBAFqmQuR642aVq6fQBjczIpQAQald7AoSrSL8AEQAPdc2G0OIULhp h+js6LM3SikjnMF6WYnnA+weC/7OyZTNzxzyeCm/xLKiJi/ciOLjWjTXUl5b5T6YuLXn Q8NA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1716256793; x=1716861593; h=to:subject:message-id:date:from:in-reply-to:references:mime-version :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=lHOU4pHYUCLeDuzhTNeHmX2grAPufVZQZ/3Z8LT3BEw=; b=PlJapYjw8zTfAu5g1lsPp/nYU5DMMSStLz3DZnQYHgAM199IhanQBu5Q9ntB743MbV 0fi4S/6x8KfLENxWuUg8uNqwbySPD0o8tiAJHlrZPEtUFU51mBG8tybbCZrAmwl48/aD byscFA0tnRxQvh8Rzd+M4dEVstyRFoyu3vabIDP6/T/3X0ezAjgIqSVLZ4ydulrHv5j5 yqgZnZkxAU7n5UxMn5HdfXpV/osNV22NWtYWvjeTMZjf6bYg8Wl9VK0ZBMPE0jhAKTqd +lYa2byZBpP7zzirUYUQMst3dTpC+dH/0Hz7b5Ppp9aEpAGRfVB7j2scaA7xfAKRREJj 1nhw== X-Gm-Message-State: AOJu0Yz3qtRosFs0x8LOtoiOwmm9R2FlGdeUOsq6cYIPs2xuvaQYc5qq si6oP3OY8RuqWr3ymmlhf6bx4vKpgpyhENUAA+BhirSAxBgjVNJSa7uHuK4W9n7BqghGZZXtcjP X23grK1ECa97L1DyTNSm35hmAJzS0/0uB X-Google-Smtp-Source: AGHT+IG5x3Xt0Tf0WPDJh7E4nmsqXlUP8NOhlFkL9z/vSdOHbgBOvHFOAM0I1RvZCYc4jdr0gQrH2W5Br4QKmWEh1vw= X-Received: by 2002:a05:6122:a19:b0:4d3:4ac2:29f4 with SMTP id 71dfb90a1353d-4df88286136mr27207039e0c.2.1716256793391; Mon, 20 May 2024 18:59:53 -0700 (PDT) Precedence: bulk list-help: list-post: List-Id: internals.lists.php.net MIME-Version: 1.0 References: <878c09ca-860e-4c0c-85ae-2cd0246cda3c@rwec.co.uk> <5014b401-6341-44c6-a16e-f453ab52220c@app.fastmail.com> <47E8FDF4-9805-4A0B-A2E1-55CF8721253E@rwec.co.uk> <133158d0-1371-4b7c-a2f4-242bfe99ce10@app.fastmail.com> <664BDE7C.8080509@adviesenzo.nl> In-Reply-To: <664BDE7C.8080509@adviesenzo.nl> Date: Mon, 20 May 2024 22:59:16 -0300 Message-ID: Subject: Re: [PHP-DEV] [DISCUSSION] Checking uninitialized class properties To: internals@lists.php.net Content-Type: multipart/alternative; boundary="0000000000008377f60618ed2c98" From: ericklima.comp@gmail.com (Erick de Azevedo Lima) --0000000000008377f60618ed2c98 Content-Type: text/plain; charset="UTF-8" > If we're talking syntax and introducing new keywords anyway, why not go with a new language construct like `is_initialized($obj->property)` ? It was one of my suggestions at the beginning of the thread. Also, I said that I'd love the "$objectVar->property is uninitialized" (answering to Larry) because of the Pattern Matching RFC ( https://wiki.php.net/rfc/pattern-matching), which adds this "is" checking for lots of stuff and, maybe if Larry and Ilija want it, this "uninitialized" could be one more pattern of this RFC. -- Erick --0000000000008377f60618ed2c98 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
> If we're talking synta= x and introducing new keywords anyway, why not go with a new language construct like `is_initialized($obj->property)` ?

It was o= ne of my suggestions at the beginning of the thread. Also, I said that I= 9;d love the "$objectVar->property is uninitialized" (answerin= g to Larry)
because of the Pattern Matching RFC (https://wiki.php.ne= t/rfc/pattern-matching), which adds this "is" checking for lo= ts of stuff and, maybe if Larry and Ilija want it,
this "uni= nitialized" could be one more pattern of this RFC.

<= /div>--
Erick
--0000000000008377f60618ed2c98--