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

Drop Default impl from ListStore #975

Closed
bilelmoussaoui opened this issue Feb 9, 2023 · 4 comments · Fixed by #1032
Closed

Drop Default impl from ListStore #975

bilelmoussaoui opened this issue Feb 9, 2023 · 4 comments · Fixed by #1032
Labels
bug Something isn't working gio
Milestone

Comments

@bilelmoussaoui
Copy link
Member

Maybe just rename the constructor to something else to avoid foot guns with #[derive(Default)]

@bilelmoussaoui bilelmoussaoui added bug Something isn't working gio labels Feb 9, 2023
@sdroege sdroege added this to the 0.18.0 milestone Feb 9, 2023
@sdroege
Copy link
Member

sdroege commented Feb 9, 2023

There's no problem with the new() function because it takes a parameter. That can stay as it is :)

@bilelmoussaoui
Copy link
Member Author

There's no problem with the new() function because it takes a parameter. That can stay as it is :)

Yes, I meant replacing ListStore::default() with something like ListStore::default_object()

@sdroege
Copy link
Member

sdroege commented Feb 9, 2023

I would just remove that one. What is it good for?

@pbor
Copy link
Contributor

pbor commented Feb 26, 2023

The Default is generated because gir generates one every time generate_builder is true. We need a new flag in gir or better heuristic

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working gio
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants