[Python-Dev] unsubscriptable vs object does not support indexing (original) (raw)
Dino Viehland dinov at microsoft.com
Wed Sep 23 22:47:41 CEST 2009
- Previous message: [Python-Dev] unsubscriptable vs object does not support indexing
- Next message: [Python-Dev] unsubscriptable vs object does not support indexing
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Brett wrote:
Let's ignore history, which I bet is the reason for the distinction, and just look at the error messages; does the distinction make sense to a newbie? I would say no and that the "does not support indexing" error message is more useful. For expert programmers they could figure out the problem with either error message. The only help is if you are trying to debug a type, but I am willing to bet most of us didn't know the distinction at the C level until David looked it up.
So I am +1 on unified the message and +1 on using the "does not support indexing" one.
I'd be +1 on the unified message as well - but it seems what that message should be may be contentious (and quite a bike shed discussion at that). The bug David linked to (http://bugs.python.org/issue5760) has a preference for subscript because that's what's used elsewhere in the language.
- Previous message: [Python-Dev] unsubscriptable vs object does not support indexing
- Next message: [Python-Dev] unsubscriptable vs object does not support indexing
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]