Closed steveberdy closed 3 years ago
Hi @viralogic. Could you please run workflows for this PR? Thanks.
@viralogic I had deleted the fork, so I can't add any more commits to this PR even if I recreate the fork (which I did). Maybe we can merge this PR and then I'll follow up immediately with a new one that renames to-dict to to-dictionary. Will that be fine?
Here is my branch where I made the most recent changes and renamed the method: steveberdy:dict-branch
@steveberdy I have merged your PR so that you can proceed with the renaming.
Thanks
@viralogic see #67 for the latest PR
Added a
to_dict
method with the functionality of .NET'sSystem.Linq.Enumerable.ToDictionary
method. One parameter is for a lambda that assigns keys according to the items in the collection, while the other parameter is an optional lambda that assigns values to the dictionary according to the items in the collection. Values default to the individual items in the collection, while keys must be specified. Docs were updated and tests were added as well.Closes #63