
    MhZ                    *    d dl mZ d dlmZmZ d	dZdS )
    )annotations)AnyDictthisDict[Any, Any]thatreturnc                @   |                                  D ]e\  }}t          |t                    r<||v r7t          ||         t                    rt          | |         ||                    V||v r||         | |<   f|                                 D ]\  }}|| vr|| |<   | S )a  Merge two nested dictionaries.

    Effectively a recursive ``dict.update``.

    Examples
    --------
    Merge two flat dictionaries:
    >>> nested_update(
    ...     {'a': 1, 'b': 2},
    ...     {'b': 3, 'c': 4}
    ... )
    {'a': 1, 'b': 3, 'c': 4}

    Merge two nested dictionaries:
    >>> nested_update(
    ...     {'x': {'a': 1, 'b': 2}, 'y': 5, 'z': 6},
    ...     {'x': {'b': 3, 'c': 4}, 'z': 7, '0': 8},
    ... )
    {'x': {'a': 1, 'b': 3, 'c': 4}, 'y': 5, 'z': 7, '0': 8}

    )items
isinstancedictnested_update)r   r   keyvalues       ]/var/www/html/test/jupyter/venv/lib/python3.11/site-packages/traitlets/utils/nested_update.pyr   r      s    , jjll " "
UeT"" 	"d{{z$s)T::{d3ic333D[[S	DIjjll  
Ud??DIK    N)r   r   r   r   r	   r   )
__future__r   typingr   r   r    r   r   <module>r      sO    # " " " " "        ! ! ! ! ! !r   