+
    i	                         R t ^ RIHtHtHtHtHt ]'       d   ^ RIHt R.t	]! RRR7      t
] ! R R]]
,          4      4       tR# )	z3A module containing the `_NestedSequence` protocol.)TYPE_CHECKINGAnyProtocolTypeVarruntime_checkable)Iterator_NestedSequence_T_coT)	covariantc                      a  ] tR t^t o RtV 3R lR ltV 3R lR ltV 3R lR ltV 3R lR	 ltV 3R
 lR lt	V 3R lR lt
V 3R lR ltRtV tR# )r   aP  A protocol for representing nested sequences.

Warning
-------
`_NestedSequence` currently does not work in combination with typevars,
*e.g.* ``def func(a: _NestedSequnce[T]) -> T: ...``.

See Also
--------
collections.abc.Sequence
    ABCs for read-only and mutable :term:`sequences`.

Examples
--------
.. code-block:: python

    >>> from typing import TYPE_CHECKING
    >>> import numpy as np
    >>> from numpy._typing import _NestedSequence

    >>> def get_dtype(seq: _NestedSequence[float]) -> np.dtype[np.float64]:
    ...     return np.asarray(seq).dtype

    >>> a = get_dtype([1.0])
    >>> b = get_dtype([[1.0]])
    >>> c = get_dtype([[[1.0]]])
    >>> d = get_dtype([[[[1.0]]]])

    >>> if TYPE_CHECKING:
    ...     reveal_locals()
    ...     # note: Revealed local types are:
    ...     # note:     a: numpy.dtype[numpy.floating[numpy._typing._64Bit]]
    ...     # note:     b: numpy.dtype[numpy.floating[numpy._typing._64Bit]]
    ...     # note:     c: numpy.dtype[numpy.floating[numpy._typing._64Bit]]
    ...     # note:     d: numpy.dtype[numpy.floating[numpy._typing._64Bit]]

c                    < V ^8  d   QhRS[ /# )   returnint)format__classdict__s   "@/usr/lib/python3/dist-packages/numpy/_typing/_nested_sequence.py__annotate___NestedSequence.__annotate__5   s     " "C "    c                   \         h)zImplement ``len(self)``.NotImplementedErrorselfs   "r   __len___NestedSequence.__len__5       !!r   c                $   < V ^8  d   QhRS[ RR/# )r   indexr   z_T_co | _NestedSequence[_T_co]r   )r   r   s   "r   r   r   9   s     " " ",L "r   c                   \         h)zImplement ``self[x]``.r   )r   r    s   ""r   __getitem___NestedSequence.__getitem__9   r   r   c                &   < V ^8  d   QhRS[ RS[/# )r   xr   )objectbool)r   r   s   "r   r   r   =   s     " "f "D "r   c                   \         h)zImplement ``x in self``.r   )r   r%   s   ""r   __contains___NestedSequence.__contains__=   r   r   c                   < V ^8  d   QhRR/# r   r   z(Iterator[_T_co | _NestedSequence[_T_co]] )r   r   s   "r   r   r   A   s     " "G "r   c                   \         h)zImplement ``iter(self)``.r   r   s   "r   __iter___NestedSequence.__iter__A   r   r   c                   < V ^8  d   QhRR/# r,   r-   )r   r   s   "r   r   r   E   s     " "!K "r   c                   \         h)zImplement ``reversed(self)``.r   r   s   "r   __reversed___NestedSequence.__reversed__E   r   r   c                &   < V ^8  d   QhRS[ RS[/# r   valuer   r   r   )r   r   s   "r   r   r   I        " "3 "c "r   c                   \         h)z,Return the number of occurrences of `value`.r   r   r7   s   ""r   count_NestedSequence.countI   r   r   c                &   < V ^8  d   QhRS[ RS[/# r6   r8   )r   r   s   "r   r   r   M   r9   r   c                   \         h)z"Return the first index of `value`.r   r;   s   ""r   r    _NestedSequence.indexM   r   r   r-   N)__name__
__module____qualname____firstlineno____doc__r   r"   r)   r/   r3   r<   r    __static_attributes____classdictcell__)r   s   @r   r   r      sQ     $L" "" "" "" "" "" "" "r   N)rE   typingr   r   r   r   r   collections.abcr   __all__r	   r   r-   r   r   <module>rK      sJ    9 K K(
4( A"huo A" A"r   