Skip to content

Latest commit

 

History

History
11 lines (7 loc) · 524 Bytes

FunctionShouldHaveReturn.md

File metadata and controls

11 lines (7 loc) · 524 Bytes

The function should have return (FunctionShouldHaveReturn)

Description

Function differs from a Procedure only that it necessarily returns a value and can be used in expressions.

Based on the above-mentioned, a function which does not contain a return is itself erroneous. Corrections required:

  • implement return if the implemented method is a function
  • rewrite function to procedure if return is not needed