c/language/return

Terminates current function and returns specified value to the caller function.

Explanation
@1@ Evaluates the, terminates the current function and returns the result of the to the caller (the value returned becomes the value of the function call expression). Only valid if the function return type is not. @2@ Terminates the current function. Only valid if the function return type is.

If the type of the is different from the return type of the function, its value is  as if by assignment to an object whose type is the return type of the function, except that overlap between object representations is permitted:

If the return type is a real floating type, the result may be represented in greater range and precision than implied by the new type.

Reaching the end of a function returning is equivalent to. Reaching the end of any other value-returning function is undefined behavior if the result of the function is used in an expression (it is allowed to discard such return value). For, see.