fn count_parameters(param_list: &ParamList) -> usize
Helper function to count the parameters including self
self