On 04/04/2013 07:38 AM Maciej Fijalkowski wrote:
On Thu, Apr 4, 2013 at 1:25 AM, Alex Gaynor<alex.gay...@gmail.com>  wrote:
Not your fault, those occur on default as well. I don't know of any way to
get better messages.

Alex

The problem is that in dicts (rpython dicts responsible for
W_DictObject and W_SetObject), we want to know that keys are non-null.
We already do, noone stores null there, but the annotator doesn't
know. I have a bit no clue how to find out all the places that pass
W_Root-or-None instead of W_Root as keys (or values), but I don't
care. Maybe we should just disable this warning.


PMJI without understanding your context, but if "noone stores null there,"
couldn't you turn the warning around to warn when/if someone *does*
store a null "there," and disable the current warning? (I'm naively assuming
all the places that pass W_Root-or-None pass it to/through one/few place/s that
can be monitored on the way to becoming keys (which I guess never happens?)).

Regards,
Bengt Richter

_______________________________________________
pypy-dev mailing list
pypy-dev@python.org
http://mail.python.org/mailman/listinfo/pypy-dev

Reply via email to