Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve support for large objects (more than 960 keys, usually used as hash table) #37

Closed
be5invis opened this issue Mar 23, 2016 · 2 comments

Comments

@be5invis
Copy link

No description provided.

@kgabis
Copy link
Owner

kgabis commented Apr 5, 2016

I don't want to change the way keys are stored and accessed right now. The implementation is simple and adding a key is an O(1) operation (ignoring a possible reallocation). If you need a hash table with O(1) access time then using parson is not the right choice. You can parse an object using parson and then put all key/value pairs into an actual hash table.

@kgabis kgabis closed this as completed Apr 5, 2016
@kgabis
Copy link
Owner

kgabis commented Jul 30, 2021

So what I wrote 5 years ago is incorrect. Adding a key is O(n) because it first checks if given key already exists (linear search). I'm currently working on using hash tables in json objects.

@kgabis kgabis reopened this Jul 30, 2021
@kgabis kgabis pinned this issue Aug 1, 2021
kgabis added a commit that referenced this issue Aug 5, 2021
@kgabis kgabis closed this as completed Aug 5, 2021
@kgabis kgabis unpinned this issue Aug 6, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants