Apologies in advance for beating this dead horse... Damian Conway wrote: > Garrett Goebel wrote: > > > What was the reason again which Larry rejected unifying the > > syntax for array > > and hash indexing? > > Because some things have both, and do different things with each.
Ok $0 is special. But isn't it _the_ special case? And strictly speaking, its an ordered associative array right? It doesn't really need the full range of expression offered by $0{...} and $0[...]. All it needs is $0[1] for ordered lookups and $0["1"] for named lookups. Or going back to the statement that "some things have both". Silly question I'm sure, but can you imagine a collection object that really needs $0[1] and $0{1}? And wouldn't it be a fair argument that such a collection object is too fancy for its own good? Hmm... $0[$!] However isn't that something the collection object should have to deal with? It seems like such nice thing to unify collection syntax. Then in Perl6 we'd have scalars and containers. We'd still give sigils to arrays and hashes as befits their perl heritage. Other collection objects could either be derived from arrays and hashes, use some other generic sigil or define their own. > And because some built-in redundancy is useful for error checking, > especially on complex nested data structures. I'm no one to argue with that... -- Garrett Goebel IS Development Specialist ScriptPro Direct: 913.403.5261 5828 Reeds Road Main: 913.384.1008 Mission, KS 66202 Fax: 913.384.2180 www.scriptpro.com [EMAIL PROTECTED]