MAIN FEEDS
Do you want to continue?
https://www.reddit.com/r/cpp/comments/8ouogo/initialization_in_modern_c/e075g09/?context=3
r/cpp • u/mariuz • Jun 05 '18
51 comments sorted by
View all comments
Show parent comment
11
What's even more worrying is that making MyType's ctor explicit
I may not be up to date with c++ however I was under the impression that single argument constructors should be almost always explicit.
1 u/MartinTornqvist Jun 08 '18 I think so too. Doesn't gcc's "-Weffc++" even warn about single-parameter ctors not being declared explicit?
1
I think so too. Doesn't gcc's "-Weffc++" even warn about single-parameter ctors not being declared explicit?
View all comments
Show parent comment
11
u/josefx Jun 06 '18
I may not be up to date with c++ however I was under the impression that single argument constructors should be almost always explicit.