Format: application/x-python-code
1 o
2
3 �hg � @ s� d Z ddlmZ ddlmZ ddlmZ ddlmZmZm Z m
4 Z
5 ddlmZ ddl
6 mZ ddlmZ e� Zd d
7 � Zeed�ejdd
8 � ��Zdd� ZG dd� de �ZG dd� de
9 �ZG dd� de�ZG dd� de�ZdS )a�
10 A module to deal with stuff like `list.append` and `set.add`.
11
12 Array modifications
13 *******************
14
15 If the content of an array (``set``/``list``) is requested somewhere, the
16 current module will be checked for appearances of ``arr.append``,
17 ``arr.insert``, etc. If the ``arr`` name points to an actual array, the
18 content will be added
19
20 This can be really cpu intensive, as you can imagine. Because |jedi| has to
21 follow **every** ``append`` and check whether it's the right array. However this
22 works pretty good, because in *slow* cases, the recursion detector and other
23 settings will stop this process.
24
25 It is important to note that:
26
27 1. Array modifications work only in the current module.
28 2. Jedi only checks Array additions; ``list.pop``, etc are ignored.
29 � )�debug)�settings)� recursion)�ValueSet� NO_VALUES�HelperValueMixin�ValueWrapper)�LazyKnownValues)�infer_call_of_leaf)�inference_state_method_cachec C s |j dvrtS t| |�S )zI Just a mapper function for the internal _internal_check_array_additions )�list�set)Z
30 array_typer �_internal_check_array_additions)�context�sequence� r �Yc:\Users\shubh\Videos\agent\nova\Lib\site-packages\jedi/inference/value/dynamic_arrays.py�check_array_additions"