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

refactor(container/gtree): refactor code with gods package #3595

Merged
merged 5 commits into from
Jun 13, 2024

Conversation

oldme-git
Copy link
Member

@oldme-git oldme-git commented May 21, 2024

Dear review:
先实现了 gtree ,如果可以再进一步处理其他的。不过我觉得 IteratorFrom 相关的方法可以废弃掉@gqcn

重构使用了新的思路:private 方法,比如 doSet, doGet, doRemove,它们用来和 gods 底层交互,处理一些简单的逻辑判断; public 方法,比如 Set, Get, SetOrGet ,它们用来调用私有方法实现框架功能,它们会携带框架相关逻辑,比如锁,gvar

@gqcn
Copy link
Member

gqcn commented May 21, 2024

It may take some time reviewing.

@gqcn gqcn added the awesome It's awesome! We keep watching. label May 23, 2024
@gqcn gqcn merged commit ffbe9a7 into gogf:master Jun 13, 2024
23 checks passed
@oldme-git oldme-git deleted the gtree branch June 18, 2024 08:55
@houseme
Copy link
Member

houseme commented Jun 25, 2024

依赖了这个包,github.com/emirpasic/gods,当前这个包的go.version 要求是1.21,gf的golang版本准备升级吗?@gqcn @oldme-git
https://github.com/emirpasic/gods/blob/14f714261f50e6d3e4af1cd29e4ae11ffdedab94/go.mod#L3

@oldme-git
Copy link
Member Author

@houseme gf 引用的是 gods v1.18.1 版本的,最低依赖是 go 1.2
https://github.com/emirpasic/gods/blob/v1.18.1/go.mod

@Issues-translate-bot
Copy link

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


@houseme gf refers to the gods v1.18.1 version, and the minimum dependency is go 1.2
https://github.com/emirpasic/gods/blob/v1.18.1/go.mod

@houseme
Copy link
Member

houseme commented Jun 25, 2024

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿

@houseme gf refers to the gods v1.18.1 version, and the minimum dependency is go 1.2 https://github.com/emirpasic/gods/blob/v1.18.1/go.mod

新版是使用了go语言的cmp包,需要升级到1.21,好几个第三方依赖都升级到了1.21

@gqcn gqcn changed the title container/gtree: refactor code with gods package refactor(container/gtree): refactor code with gods package Jun 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
awesome It's awesome! We keep watching.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants