Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:101152 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 72915 invoked from network); 24 Nov 2017 13:21:27 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 24 Nov 2017 13:21:27 -0000 Authentication-Results: pb1.pair.com smtp.mail=rowan.collins@gmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=rowan.collins@gmail.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 74.125.82.43 as permitted sender) X-PHP-List-Original-Sender: rowan.collins@gmail.com X-Host-Fingerprint: 74.125.82.43 mail-wm0-f43.google.com Received: from [74.125.82.43] ([74.125.82.43:35747] helo=mail-wm0-f43.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 86/61-60763-4DC181A5 for ; Fri, 24 Nov 2017 08:21:26 -0500 Received: by mail-wm0-f43.google.com with SMTP id y80so22550119wmd.0 for ; Fri, 24 Nov 2017 05:21:24 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:user-agent:in-reply-to:references:mime-version :content-transfer-encoding:subject:to:from:message-id; bh=Da66VUM6Lz1zCMXANANwx0HNTqSpfIikFD5vBv2aItw=; b=hHdrW7/MdjtD71ET+F/EJH+wrjGTiCiWcP3V+KKpinMQ1bx0xzLC8qjJT4zsoJq3Ft qL/VFtSBpw2wkzgK9JmlZMdpzu34I6Xxpaq1aqCD99TfX8jnEWn97EWh6g0ihUe7sVaC ny0gE4RP4Fju60CcKjdj+sFSO7bIxKuO77VFoKW8C4z9CopT/FTcKRFqwI6SDPj+pFQa fNucI0iobtYag5gFyKUaqzQU0SaKKXyR6xtxydYYzSlXX8H0yqYUkdVwuFIMxH2s+5A+ pGsREjUarHBwHVQurBJrt5MpHbhPdN6nlMbOCFzNB0XX3mGldy7M1jueOVlcCVHjF7C4 wWMw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:user-agent:in-reply-to:references :mime-version:content-transfer-encoding:subject:to:from:message-id; bh=Da66VUM6Lz1zCMXANANwx0HNTqSpfIikFD5vBv2aItw=; b=pJnRt5pRbKvNryhM/AYkXCX1zwN3rs/dW8bZK7k9xSeXT79e333dSF73AQ+53CDaVz YIFk2N8XJZUG5H7e17mRSbI+9GwRZX/L58RhjbIiWJA8+cQXJvaDkWT9VKbpcorEGg0m qKM7+x2F81rc6f/75wIORnqn16k+/2eC+SMzJWLEKUhsr58SK+vgILM5qp3lt09w94/i u6Jok3+guLG2FWx74hC1retuc0n8A1QAgJjM5ghICSOpfACfazKHrS3Ww3/C8VEF5ip9 j89EPb9mSHNEsOznVwcIyO9WZbGmEEuI/ULakF40Q9Iw0XINmnCSrb1BMnU7H8QuhQhH PA2g== X-Gm-Message-State: AJaThX7akQzGCG3ujWjYMdvW/iu1kica2gXbtx+RPipKo96h+XqXLIXk xxSw7sYgZ8YI+iaBZ7I24vZy1z9f X-Google-Smtp-Source: AGs4zMaC+DoPsE0FqYHEGH2K3Bhxjx6I9xIwwjfkfbk8LLyvEZNaP/t9IeBBkbHLdstWCq6frdEb0w== X-Received: by 10.80.186.193 with SMTP id x59mr40299701ede.256.1511529681762; Fri, 24 Nov 2017 05:21:21 -0800 (PST) Received: from [10.60.157.40] (188.29.164.58.threembb.co.uk. [188.29.164.58]) by smtp.gmail.com with ESMTPSA id g45sm15731975eda.88.2017.11.24.05.21.20 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 24 Nov 2017 05:21:20 -0800 (PST) Date: Fri, 24 Nov 2017 13:21:17 +0000 User-Agent: K-9 Mail for Android In-Reply-To: References: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable To: internals@lists.php.net,"Khawer ." Message-ID: <12F58DFE-B842-44FB-ACF6-FB62F4BB1F7A@gmail.com> Subject: Re: [PHP-DEV] Changes in namespace importing From: rowan.collins@gmail.com (Rowan Collins) On 24 November 2017 07:05:52 GMT+00:00, "Khawer =2E" wrote: >We use 'use' keyword to import other namespaces, namespace classes, >namespace functions, and namespace constants=2E > >Example >1) use abc; (Import abc namespace) >2) use abc\ClassB; (Import ClassB from abc namespace) Although these are described in the manual as separate types of import, th= ey are actually the same: they alias a prefix used to rewrite class names w= hen you mention them=2E If you have a class "One\Two\Test" and a class "One\Two", then "use One\Tw= o" will allow you to access them as "Two\Test" and "Two", respectively=2E h= ttps://3v4l=2Eorg/nQ7pB Similarly, if you alias a prefix with "use Foo as Bar", then "new Bar\Test= " will refer to class "Foo\Test", and "new Bar" will refer to class "Foo"= =2E https://3v4l=2Eorg/2r6WN So "use class" wouldn't make sense, because that's not actually what happe= ns=2E Regards, --=20 Rowan Collins [IMSoP]