The Voidspace Techie Blog

if you get something from x[6j] it's mapping.


Gravatar Yeah - good point.


Gravatar It's possible to implement a mapping type that doesn't rely on hashing the keys - for example, a binary search tree.

I think your best bet is just relying on the fact that sequence types won't work if you pass them something that isn't an integer. (Although if someone's using a custom sequence type that does something different in that case (fairly pathological situation), you'll still have a problem.)


Name:

Email:

URL:

Comment:  ? 

 

Commenting by HaloScan