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

Using std::vector instead of Array #259

Open
rocallahan opened this issue Jul 5, 2024 · 1 comment
Open

Using std::vector instead of Array #259

rocallahan opened this issue Jul 5, 2024 · 1 comment

Comments

@rocallahan
Copy link

The Array class has almost exactly the same functionality and implementation as std::vector, except that it requires manual cleanup via clear() instead of automatic destruction, and lacks various C++ conveniences like constructors and support for (element : array) syntax. Would you be open to PRs that replace Array usage with std::vector?

Pros: shorter, more idiomatic, somewhat safer C++ code
Cons: would change the C++ API. Are you committed to preserving compatibility with the current API?

@heitzmann
Copy link
Owner

I don't really like the whole constructor/destructor machinery, but seeing as I have less and less time to dedicate to the project, this change might make it mora approachable to new contributors.

So, I'm open to "modernizing" the code as long as our benchmarks don't suffer significantly.

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