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

Clone optimization #4

Merged
merged 1 commit into from
Mar 28, 2017
Merged

Clone optimization #4

merged 1 commit into from
Mar 28, 2017

Conversation

bali182
Copy link
Contributor

@bali182 bali182 commented Mar 28, 2017

This change moves the check-if-array-or-object check out of the clone method, and does it once at creation time. Since we are talking about immutable structures, it is unnecessary to check each time when cloning if the given object is still of the same type.

@sdgluck sdgluck merged commit c9d9939 into sdgluck:master Mar 28, 2017
@sdgluck
Copy link
Owner

sdgluck commented Mar 28, 2017

Thank you!

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

Successfully merging this pull request may close these issues.

2 participants