this question has answer here:
foo(const t& t);
vs
foo(t const& t);
as far know, same. difference purely style thing. can gather former more 'old school' approach, whilst later might see more in newer books.
is there difference, superficially and/or getting down gritty detail?
is there reason choose 1 on other, besides sticking convention within code-base?
they're same. latter more consistent because const
appears after thing modifies.
if const
appears before end of type-specifier sequence, it's pushed end of it. simple that.
of course, english puts adjectives before modified item. of course, c++ isn't english (and not speaks english anyway).
Comments
Post a Comment