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

Kernel Vector Library #295

Closed
Kfeavel opened this issue Aug 12, 2021 · 6 comments
Closed

Kernel Vector Library #295

Kfeavel opened this issue Aug 12, 2021 · 6 comments
Labels
feature Additional functionality

Comments

@Kfeavel
Copy link
Member

Kfeavel commented Aug 12, 2021

The kernel should have a vector library similar to that of the C++ standard library's vector. It should be templated like LinkedList and should accept a maximum size so that it can be statically allocated.

@Kfeavel Kfeavel added the feature Additional functionality label Aug 12, 2021
@micahswitzer
Copy link
Member

So this vector will not allow for growing and shrinking like the standard library one does?

@Kfeavel
Copy link
Member Author

Kfeavel commented Aug 13, 2021

Ideally it would, yes. Maybe there should be a base class that a dynamic and a static variation could both inherit?

@micahswitzer
Copy link
Member

That would be the "proper" OOP way to do that, but I get the feeling that it would be much more performant to have completely separate implementations that just so happen to have the same API. We'll have to experiment and see what's best.

@Kfeavel
Copy link
Member Author

Kfeavel commented Aug 13, 2021

What if it was the difference between an Array class and a Vector class? Array uses statically sized arrays and Vector used a dynamically allocated array so that it can be resized.

@micahswitzer
Copy link
Member

That sounds good in theory. I guess we'll have to play around with implementation and see how it fits.

@Kfeavel
Copy link
Member Author

Kfeavel commented Feb 12, 2022

Closing this issue as it's being rolled into #378 (XS standard library)

@Kfeavel Kfeavel closed this as completed Feb 12, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature Additional functionality
Projects
None yet
Development

No branches or pull requests

2 participants