#28893: Narrow dict.items() calls to .keys()/.items()
--------------------------------------+------------------------------------
     Reporter:  Дилян Палаузов        |                    Owner:  nobody
         Type:  Cleanup/optimization  |                   Status:  new
    Component:  Core (Other)          |                  Version:  master
     Severity:  Normal                |               Resolution:
     Keywords:                        |             Triage Stage:  Accepted
    Has patch:  1                     |      Needs documentation:  0
  Needs tests:  0                     |  Patch needs improvement:  1
Easy pickings:  0                     |                    UI/UX:  0
--------------------------------------+------------------------------------

Comment (by Дилян Палаузов):

 Yes, it is better not to apply the last snippet in debug.py.

 I know that iterating over a {{{dict:}}} and {{{dict.keys():}}} is
 effectively the same, but while the later returns (an iterator of) a view,
 I don't know what the former returns and therefore whether both forms are
 really equivalent.

-- 
Ticket URL: <https://code.djangoproject.com/ticket/28893#comment:3>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/072.b9abfc9817be31e243ff190923d74d4d%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to