Well, given how much PHP has copied from C (and I mean that in a good
way), why not copy the sane, less-controversial namespace separator
and behavior that we all know and love?
\Tudor
On Sun, Oct 26, 2008 at 4:23 PM, Lester Caine [EMAIL PROTECTED] wrote:
Tudor Prodan wrote:
PHP has to be
On Mon, Oct 27, 2008 at 12:33 PM, Tudor Prodan [EMAIL PROTECTED] wrote:
Well, given how much PHP has copied from C (and I mean that in a good
way), why not copy the sane, less-controversial namespace separator
and behavior that we all know and love?
because C is static, and PHP is dynamic
it
I want to express my happiness of finally having an agreement/solution for
the namespaces.
I have something like 70 000 LOC with namespaces (and a lot of static
calls/class consts) so it will take some time to convert it to \ but I'm
still very happy to have a solution. Like Karsten Dambekalns
Lester Caine wrote:
The backslash is not ideal, but I think we all need to get behind it
rather than complaining. The only other real alternative today is to
shelve namespaces altogether for the next release rather than putting
something in that is simply not practical to extend later?
I'd
This was argued for months, there was tons of emails to read and backslash
is best for most people. PHP is dynamic language - that makes some major
restrictions, so you just can't apply something that is already in use
easily. That's why :: was rejected in first place. That's why . was
rejected,
So does that mean the new NS operator is actually \\ and not \ ?
No developer is going to be relying on single \'s -- too likely to become an
error in maintenence, and too inconsistent (see strings discussion).
Jevon
On Tue, Oct 28, 2008 at 12:11 AM, Arvids Godjuks
[EMAIL PROTECTED]wrote:
I disagree that PHP being a dynamic language justifies the introduction
of deeply unpopular syntax. I mean, PHP developers are your end users.
Bad past design decisions aside, you don't want to alienate your users.
And yes, this has probably been argued in the past. Unfortunately, it
looks
On Mon, 27 Oct 2008, Thomas Lee wrote:
I disagree that PHP being a dynamic language justifies the
introduction of deeply unpopular syntax. I mean, PHP developers are
your end users. Bad past design decisions aside, you don't want to
alienate your users.
And yes, this has probably been
Hi Thomas,
Anyway, my point is that there may be other options. Such as putting off a
long-sought feature until it can be implemented properly.
OK, since you obviously didn't do any background reading before posting to
this list, let me direct you to the history behind this decision once
I apologise for being silent on this issue to date (been busy), but I feel that
I must comment even if the decision is now 'final'.
On Mon, Oct 27, 2008 at 10:38:07PM +1100, Thomas Lee wrote:
I disagree that PHP being a dynamic language justifies the introduction
of deeply unpopular syntax. I
I agree with Thomas Lee, if the backslash ever gets released, it's
there forever.
Who uses functions and variables in a namespace anyway? very few
Will that small part of the users even use namespaces? probably not
So, why not ban these from namespaces and save all the trouble?
If however a user
On Mon, 27 Oct 2008, Thomas Lee wrote:
How would delyaing it help?
I agree, delaying will not help (and namespaces are the most expected
feature in PHP 5.3).
If we could have made :: work, we would have. Greg (and others)
spend countless hours trying out different concepts, with different
1. One user of namespaced constants functions here... I dont like to use
objects for everything. I have very few constants functions but I would
like them to remain constants functions instead of converting them to
static classes or object methods.
2. One reason against dropping ns for
Steph Fox wrote:
Hi Thomas,
Anyway, my point is that there may be other options. Such as putting
off a long-sought feature until it can be implemented properly.
OK, since you obviously didn't do any background reading before
posting to this list, let me direct you to the history behind
David Grudl wrote:
But what is the purpose of namespaces? To give developers their own
separated space. And it is their responsibility to not use ambiguous
names. PHP has not problem with class Foo::Bar and namespace Foo::Bar,
but coding standards usually prohibits it.
+1 to that.
Hi Thomas,
Actually I've been following namespaces for a fair while, but the issue of
:: being a problem wasn't really raised until a few weeks ago. So while
I'm aware of namespaces being under discussion for a fair while, yesterday
was the first I'd heard about a decision being made for the
Actually I've been following namespaces for a fair while, but the
issue of :: being a problem wasn't really raised until a few weeks
ago.
I realize this isn't a terribly constructive comment as it doesn't
solve any problems, but I hope it's constructive in the way that it
actually causes
Hi!
If you read everything linked from that RFC, you will discover that
there are two ways to implement namespace support in PHP 'properly'.
1) We can offer support for classes only and throw a fatal error when a
function is encountered in namespaced code
2) We can use a namespace separator
These aren't the only ways.
OK.
4) Claim that there is no real problem in addressing ambiguous situations.
- Steph
--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php
Hi!
OK.
4) Claim that there is no real problem in addressing ambiguous situations.
This is not what I meant, but there's obviously neither use nor interest
in further discussing this topic as decision was already taken. I only
wish people would not start rewriting history as other opinions
This is not what I meant, but there's obviously neither use nor interest
in further discussing this topic as decision was already taken. I only
wish people would not start rewriting history as other opinions or options
didn't even exist so soon. I'm fine with making the choice, what I'm not
Vesselin Kenashkov wrote:
1. One user of namespaced constants functions here... I dont like to use
objects for everything. I have very few constants functions but I would
like them to remain constants functions instead of converting them to
static classes or object methods.
2. One reason
Hi,
PHP has to be unique, using the double colon notation would be too
cliche, but if we're not respecting conventions, why not go with
something more exotic? I've always liked the o with the slash trough
it. The e with the horizontal colon is also pretty nice. The n with
the tilde over it, it so
Tudor Prodan wrote:
PHP has to be unique, using the double colon notation would be too
cliche, but if we're not respecting conventions, why not go with
something more exotic? I've always liked the o with the slash trough
it. The e with the horizontal colon is also pretty nice. The n with
the
I hope it is only very bad joke :-(
namespace myNamespace;
class theLoader
{
function load($class) { ... }
}
// somewhere else
spl_autoload_register(array(myNamespace\theLoader, load));
- registers myNamespacetabheLoader::load()
David Grudl
Původní zpráva
Předmět:
David Grudl wrote:
I hope it is only very bad joke :-(
namespace myNamespace;
class theLoader
{
function load($class) { ... }
}
// somewhere else
spl_autoload_register(array(myNamespace\theLoader, load));
- registers myNamespacetabheLoader::load()
Fortunately, there is a
26 matches
Mail list logo