def fix_method_type(string: str) -> str:
  """Fixes the method type.

  Args:
    string: A parameter type declaration

  Returns:
    A fixed up string replacing pointers to concrete types with pointers to
    void, e.g. "const int*" -> "const void*".
  """

  method_type = string.strip()

  # Const pointer
  if "*" in method_type and "const" in method_type:
    return "const void*"

  # Regular pointer
  if "*" in method_type:
    return "void*"

  # Not a pointer
  return method_type