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 is FluidDataSet default constructor marked explicit? #77

Open
weefuzzy opened this issue Jan 19, 2022 · 1 comment
Open

Why is FluidDataSet default constructor marked explicit? #77

weefuzzy opened this issue Jan 19, 2022 · 1 comment

Comments

@weefuzzy
Copy link
Member

It doesn't seem like it would have any effect on anything. The purpose of explicit is to prevent accidental implicit conversions, which isn't an issue for a constructor with no arguments. 

@AlexHarker
Copy link
Contributor

AlexHarker commented May 31, 2022

Just for fun it looks like it will do this:

https://godbolt.org/z/4xcMbqrno

and this:

https://godbolt.org/z/xccjGqxE8

Both of those compile without the explicit keyword. They are edge cases though, and I'm not sure if it's really useful to prevent these, but it doesn't have no effect.

fearn-e pushed a commit to fearn-e/flucoma-core that referenced this issue Aug 15, 2023
fluid.plotter reset points on receiving setdict()
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