Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Python does not have a default iterator for its objects. It does for dicts of course, but JS objects are not dicts (lots of issues there).


I would just think default iterators are a sensible default especially for maps and that getting them in would be worth the very slight pain it might cause people wanting to attach custom iterators.


Maps have a default iterator as shown in my slides. Sets too.

Best to take this to es-discuss. For now, we're sticking with Python, which did not give its top-class (non-dict) Object a default iterator.




Consider applying for YC's Summer 2026 batch! Applications are open till May 4

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: