Displaying 1 result from an estimated 1 matches for "parserinstance".
2018 Nov 25
6
RFC: Modernizing our use of auto
...the coding guidelines suggest that is ok:
https://llvm.org/docs/CodingStandards.html#beware-unnecessary-copies-with-auto
So, perhaps the guidelines for reviewers needs to adapt, or the coding
guidelines need to adapt.
Currently, reviewers reject code of the form
void foo()
{
auto ParserInstance = Parser::getFromArgs(Args);
if (ParserInstance)
obj.someApi(ParserInstance);
}
as unreadable while
void foo()
{
obj.otherApi(Parser::getFromArgs(Args));
}
is fine. It would be good to have an answer in the coding guidelines to
whether
void foo()
{
if (a...