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

Why not make this project into a base toolkit? #168

Closed
ZZQ001010 opened this issue May 27, 2021 · 7 comments
Closed

Why not make this project into a base toolkit? #168

ZZQ001010 opened this issue May 27, 2021 · 7 comments

Comments

@ZZQ001010
Copy link

Why not make this project into a base toolkit? Go array map is cumbersome

@ZZQ001010
Copy link
Author

Includes some thread safety control

@Zyl9393
Copy link

Zyl9393 commented Jun 8, 2021

Generics are coming. They will cause projects like this to be rewritten a lot.

@emirpasic
Copy link
Owner

@Zyl9393 Generics would solve many of the problems, but at the time of creating this project, there was direct refusal to get generics into golang from the authors themselves. So, once, and if they arrive, this will be a good addition to this project as the type casting in GoDS takes the biggest performance hit, generics would solve that .

@emirpasic
Copy link
Owner

@zzq1314zll I think the authors of golang are opinionated in that regard, keeping go simple, so I doubt they would approve of that. This does not prevent you from using GoDS as a dependency. I've created this project as I've felt that these high-level data structures were missing, given you have access to them in Java, C++ STL, etc. and we make much use of it in our daily lives. In short, it is up to the authors to decide, I have no influence over it and respect their philosophy that has created golang as one of the most popular languages... so they are doing something right keeping it simple.

@Zyl9393
Copy link

Zyl9393 commented Jun 8, 2021

@emirpasic Thanks for making this project! The Generics proposal is actually accepted, in case you missed it: https://go.googlesource.com/proposal/+/refs/heads/master/design/43651-type-parameters.md

Golang's biggest problem is that it often sacrifices correctness for the sake of simplicity. It makes it easy to get into, but hard to tackle niche problems. Generics are the obvious tip of the iceberg. Most other problems stem from the standard library sitting at 1.x for way too long. They even unnecessarily make many parts of it package-private to allow for this to go on even longer. I'm getting a bit jaded over it. Probably going to look at Rust for a change...

@emirpasic
Copy link
Owner

Generics is finally here and discussed in #179

This will be a rewrite of GoDS as v2 to keep the old version in order not to break builds and keep some backward compatability for versions prior to Golang 1.18

1 similar comment
@emirpasic
Copy link
Owner

Generics is finally here and discussed in #179

This will be a rewrite of GoDS as v2 to keep the old version in order not to break builds and keep some backward compatability for versions prior to Golang 1.18

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

3 participants