Syntactic clarification of 12-8-1 wording - Printable Version +- MISRA Discussion Forums (https://forum.misra.org.uk) +-- Forum: MISRA C++ (https://forum.misra.org.uk/forumdisplay.php?fid=18) +--- Forum: MISRA C++:2008 rules (https://forum.misra.org.uk/forumdisplay.php?fid=19) +---- Forum: 6.12 Special member functions (C++) (https://forum.misra.org.uk/forumdisplay.php?fid=141) +---- Thread: Syntactic clarification of 12-8-1 wording (/showthread.php?tid=1053) |
Syntactic clarification of 12-8-1 wording - gs - 24-04-2014 Rule 12-8-1 states: Quote:A copy constructor shall only initialize its base classes and the non-static members of the class of which it is a member.Does this sentence mean: Quote: A copy constructor may only initialize and, when doing so, may only initialize its base classes and the non-static members of the class of which it is a member.or Quote:A copy constructor may do things other than initialization but, if it does initialize, it may only initialize its base classes and the non-static members of the class of which it is a member.? Re: Syntactic clarification of 12-8-1 wording - misra cpp - 11-10-2016 The first alternative is intended |