Throw an exception if calling parent or self on MWFunction.