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

Allow planning actions to clone and return model state #37

Open
eelstork opened this issue Oct 21, 2019 · 0 comments
Open

Allow planning actions to clone and return model state #37

eelstork opened this issue Oct 21, 2019 · 0 comments
Labels
enhancement Optimize a thing

Comments

@eelstork
Copy link
Contributor

A custom clone method is helpful; allowing planning actions to provide their own has advantages:

  • A planning action knows what state it modifies. With a well structured model planning action can return a shallow copy, with only relevant sections re-allocated (uses less memory)
  • In turn this makes equality compares much faster, because un-modified refs can be detected right away.
@eelstork eelstork added the enhancement Optimize a thing label Oct 21, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Optimize a thing
Projects
None yet
Development

No branches or pull requests

1 participant