Are parentheses around the result significant in a return statement?

前端 未结 11 2374
感情败类
感情败类 2020-11-27 12:07

Is there a difference between these two statements inside a function?

bool returnValue = true;
// Code that does something
return(returnValue);
11条回答
  •  青春惊慌失措
    2020-11-27 12:35

    I assume boo is a typo, and you are asking whether there is a difference between

    return expr;
    

    and

    return(expr);
    

    The answer is no.

提交回复
热议问题