Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:107963 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 47486 invoked from network); 3 Jan 2020 01:10:47 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 3 Jan 2020 01:10:47 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id A4B53180537 for ; Thu, 2 Jan 2020 15:14:45 -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=-2.1 required=5.0 tests=BAYES_00,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 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-io1-f50.google.com (mail-io1-f50.google.com [209.85.166.50]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by php-smtp4.php.net (Postfix) with ESMTPS for ; Thu, 2 Jan 2020 15:14:42 -0800 (PST) Received: by mail-io1-f50.google.com with SMTP id r13so29733662ioa.3 for ; Thu, 02 Jan 2020 15:14:42 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=+6okbv5Uiwz3JWefXtDZQr9NLUID0HLczXkXQy6x41A=; b=HHVV5ISK5HfbkyCoqiagi+2In4b1IavfgUg0XunlL0CrwplA7WQrHvpC2zIkC9F4aQ zBpzXjfO44cpbkcq9tIQH08LniSsQiAZXTRwKw6nWvVhHJXJp9EwQaAkyLPjCeQ71c2P knCnfKAgYEuRZRyAi4trQrk3HGjaXQUwO5bIAzWSsB0rgpHOugPlK6XjBqyzj5UqmVUZ NTsoZlwVQHGU5pi4yJi/ZyYwI/bI27ojTORL6FNF3ewFt2xg97MF8mjzcFI+YB2+lIhd 0A/MJ3WPmuj4Xd/DZf0QgKMqL4UMOHHVP6z0yjKWqvGKvyUaRhGVk/o6rnxRNm8LtPuF XUuA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=+6okbv5Uiwz3JWefXtDZQr9NLUID0HLczXkXQy6x41A=; b=etU6nlh0LN+iQtGiXup8qBxcTPTejEQfUDs/S7G+6lJtAGMXvcjFwTpvpUc51EsbG6 /fNE3/lcLS/SfJk5ji2AhF2wDhf2xDZy43C7mRp/gHykn7Tbcay3dUlQaUdv5aU3PQfp FyoKnH7a+Rty2pgp23YpWSIcvU84GK5u33HqYV7ArdJioIYtW36dDIc7yX59edigjl/w Ql4iCESC8NF377/ycPzFrxR0Ph3LwKA02kQ5UITRS79nAueH4jJ0TgD6m6+i1miNVcWx QkqaJgJKoTUdpT9NZAzI4gbgpszZuDPQbbpuxqTZxXnOpmUjymlqk2lEYby02vfTF7tu XJwg== X-Gm-Message-State: APjAAAXcTuTymxdG1fCHZzCSPif7rljCOqnWbWz/KaClIy8kvyPGyZ8L Bx3Z2+1weQFqNG+WXUyDZQUgfcnNMrCHTK0lAGod+w== X-Google-Smtp-Source: APXvYqxsxbDTJ3twm+i57rAEdyrXu5PVDstf25T6kMcMW8kjlrezzp6oOigQqkt5p2YmvmNRYvONgzR7h3TL0WZtIjk= X-Received: by 2002:a6b:8d4f:: with SMTP id p76mr45965487iod.76.1578006880011; Thu, 02 Jan 2020 15:14:40 -0800 (PST) MIME-Version: 1.0 References: <5e0d723f.1c69fb81.e2ae8.24e2SMTPIN_ADDED_MISSING@mx.google.com> <74F2DBFC-E63C-428C-A37F-2D0CEE15AD0F@newclarity.net> In-Reply-To: <74F2DBFC-E63C-428C-A37F-2D0CEE15AD0F@newclarity.net> Date: Fri, 3 Jan 2020 01:14:28 +0200 Message-ID: To: Mike Schinkel Cc: PHP internals Content-Type: text/plain; charset="UTF-8" Subject: Re: [PHP-DEV] Initializing constants once, with code? From: weirdan@gmail.com (Bruce Weirdan) There's also a fourth approach that does not involve any changes to PHP: autoload + eval. When PHP is looking for your class, in your autoload you load the values from config, generate the class source and eval() it.