class_docstr: Interface specification for `Type`\s that can be arguments to a `CLinkerOp`.
  
  A `CLinkerType` instance is mainly responsible  for providing the C code that
  interfaces python objects with a C `CLinkerOp` implementation.
class_docstr_tok: ["Interface","specification","for","`","Type","`","\\s","that","can","be","arguments","to","a","`","CLinkerOp","`",".","A","`","CLinkerType","`","instance","is","mainly","responsible","for","providing","the","C","code","that","interfaces","python","objects","with","a","C","`","CLinkerOp","`","implementation","."]
docstr: Return C code to declare variables that will be instantiated by :meth:`CLinkerType.c_extract`.
  
  Parameters
  ----------
  name
      The name of the ``PyObject *`` pointer that will the value for this
      `Type`.
  sub
      A dictionary of special codes.  Most importantly
      ``sub['fail']``. See `CLinker` for more info on ``sub`` and
      ``fail``.
  
  Notes
  -----
  It is important to include the `name` inside of variables which
  are declared here, so that name collisions do not occur in the
  source file that is generated.
  
  The variable called `name` is not necessarily defined yet
  where this code is inserted. This code might be inserted to
  create class variables for example, whereas the variable `name`
  might only exist inside certain functions in that class.
  
  TODO: Why should variable declaration fail?  Is it even allowed to?
  
  Examples
  --------
  
  .. code-block: python
  
      def c_declare(self, name, sub, check_input=True):
          return "PyObject ** addr_of_%(name)s;"
code: def c_declare(
      self, name: str, sub: dict[str, str], check_input: bool = True
  ) -> str:
      """Return C code to declare variables that will be instantiated by :meth:`CLinkerType.c_extract`.
  
      Parameters
      ----------
      name
          The name of the ``PyObject *`` pointer that will the value for this
          `Type`.
      sub
          A dictionary of special codes.  Most importantly
          ``sub['fail']``. See `CLinker` for more info on ``sub`` and
          ``fail``.
  
      Notes
      -----
      It is important to include the `name` inside of variables which
      are declared here, so that name collisions do not occur in the
      source file that is generated.
  
      The variable called `name` is not necessarily defined yet
      where this code is inserted. This code might be inserted to
      create class variables for example, whereas the variable `name`
      might only exist inside certain functions in that class.
  
      TODO: Why should variable declaration fail?  Is it even allowed to?
  
      Examples
      --------
  
      .. code-block: python
  
          def c_declare(self, name, sub, check_input=True):
              return "PyObject ** addr_of_%(name)s;"
  
      """
  
imports: import typing
  import warnings
  from abc import abstractmethod
  from typing import Callable, Optional
  from pytensor.graph.basic import Apply, Constant
  from pytensor.graph.utils import MethodNotDefined
label_desc: Use image node_id 1 for calling the CLinkerType obj's underlying member method code with example usage: obj.c_declare(name, sub, check_input) without return types