stefankoegl / kdtree

A Python implementation of a kd-tree
ISC License
365 stars 118 forks source link

Modify method 'add' to return newly added node. This can be used to add ... #23

Closed ghost closed 9 years ago

ghost commented 9 years ago

...a payload to the node, e.g. tree.add(point).payload = 42. The payload can then be retrieved, e.g. print tree.search_nn(query).payload.

stefankoegl commented 9 years ago

Thanks for your pull request!

Could you please add a test that verifies the changed behaviour? I understand that the change is quite simple, but a test would ensure that the functionality is not accidentally removed or changed later on.

ghost commented 9 years ago

Test added.

stefankoegl commented 9 years ago

Thanks!

stefankoegl commented 9 years ago

I've just released 0.12 which contains your changes.

coveralls commented 7 years ago

Coverage Status

Changes Unknown when pulling 8d1c56c107addd9e6071e7791cf96e5d882d1475 on boldo:master into \ on stefankoegl:master**.