what's so difficult about namespace?

Lew noone at lewscanon.com
Wed Nov 26 14:11:31 CET 2008


Xah Lee wrote:
>> Of languages that do have namespace that i [sic] have at least working
>> expertise: Mathematica, Perl, Python, Java. Knowing these langs
>> sufficiently well, i [sic] do not see anything special about namespace. The
>> _essence_ of namespace is that a char is choosen as a separator, and
>> the compiler just use this char to split/connect identifiers.

That is hardly the essence of namespaces, just a notational convenience to 
help humans relate to namespaces.  The essence of namespaces is that they are 
distinct.

It's also not an accurate statement.  XML namespaces, for example, use many 
characters as separators, not just one, but that's not the essence.  The 
essence is that all the characters matter, not just the putative separators.

>> Although i [sic] have close to zero knowledge about compiler or parser, but
>> from a math point of view and my own 18 years of programing
>> experience, i [sic] cannot fathom what could possibly be difficult of
>> introducing or implementing a namespace mechanism into a language. I
>> do not understand, why so many languages that lacks so much needed

Point not proven.  If they were really needed in every language, every 
language would have them.

>> namespace for so long? If it is a social problem, i [sic] don't imagine they
>> would last so long. It must be some technical issue?

Yeah, like technically they aren't needed everywhere.

>> Could any compiler expert give some explanation?

Compilers are not relevant.  XML has namespaces, and compilers certainly 
aren't the issue there.

-- 
Lew



More information about the Python-list mailing list