This uses an iterator instead of walking a list, which is roughly twice as fast. This also does away with the pre-check on whether the list is valid for converting to a dict, and instead handles the case of an uneven number by catching another exception. This is preferable since it's a fatal error anyway, so avoiding it in the non-fatal case is preferable.pull/5227/merge
parent
346ab9f0d8
commit
8e1670cc60
1 changed files with 9 additions and 4 deletions
Loading…
Reference in new issue