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 is potentially overused #20

Open
pufferfish101007 opened this issue Oct 3, 2024 · 0 comments
Open

clone is potentially overused #20

pufferfish101007 opened this issue Oct 3, 2024 · 0 comments
Labels
good first issue Good for newcomers help wanted we'd like more people to get involved in this

Comments

@pufferfish101007
Copy link
Member

There's nothing wrong with a few clone()s scattered about in places to satisfy the borrow checker, but there are literally hundreds of them in HyperQuark at the moment, many of which are probably operating on potentially quite large data structures. Where possible, clones should be avoided. cloneing an Rc is fine and inevitable of course and perhaps more references (or smart pointers of some sort) should be used to help this.

@pufferfish101007 pufferfish101007 added good first issue Good for newcomers help wanted we'd like more people to get involved in this labels Oct 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers help wanted we'd like more people to get involved in this
Projects
None yet
Development

No branches or pull requests

1 participant