FunctionSanityChecks function

Checks if a function is properly formatted