code: def _validate_is_result_type(
      value: Any, result_type: type[Any]
  ) -> None:
      if result_type == Any:
          return
      if not isinstance(value, result_type):
          raise ValueError(
              'Value of last entry must be of type "{}", got "{}"'.format(
                  _get_name_of_type(result_type),
                  _get_name_of_type(type(value)),
              )
          )
  
imports: from __future__ import annotations
  import abc
  from typing import Any, Iterator, Mapping
label_desc: Use image node_id 2 for calling a global function with example usage: _validate_is_result_type(value, result_type) without return types