Forums
New posts
Search forums
Members
Current visitors
Log in
Register
What's new
Search
Search
Search titles only
By:
New posts
Search forums
Menu
Log in
Register
Install the app
Install
Forums
Archive
Archive
C++
Why can't PODs have constructors?
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
[QUOTE="JohnQ, post: 2989292"] How will the compiler be able to distinguish between using the default constructor and the one above where you gave default values to all the arguments? (This is a minor note that is off-topic for the thread). Fine. Now how about: Rect rect8(); // ambiguous Can't do that because RECT has not constructor taking a Rect arg. Are you suggesting that initializing a struct with a struct (from the RECT& operator of Rect) works? (My C-ismness, or forgetfulness thereof may be apparent). Same question as above (and excuse me if I am at times unpedantic). What you should be sorry for is making me decipher your examples rather than just stating the obvious (which I think I "summed up" in a near previous post in this thread (kind of))! :P ;) John [/QUOTE]
Verification
Post reply
Forums
Archive
Archive
C++
Why can't PODs have constructors?
Top