/snap/core22/2411/usr/lib/python3.10/test/support/__pycache__
Edit: /snap/core22/2411/usr/lib/python3.10/test/support/__pycache__/interpreters.cpython-310.pyc (7104B)
o
`wi @ s d Z ddlZddlZddlmZmZmZmZ g dZddddZ d d
Z
dd Zd
d ZG dd dZ
dd Zdd ZG dd dZe ZG dd deZG dd deZdS )z"Subinterpreters High Level Module. N)ChannelErrorChannelNotFoundErrorChannelEmptyErroris_shareable)
Interpreterget_currentget_maincreatelist_allSendChannelRecvChannelcreate_channellist_all_channelsr r r r Tisolatedc C s t j| d}t|| dS )z'Return a new (idle) Python interpreter.r )
_interpretersr r )r id r 0/usr/lib/python3.10/test/support/interpreters.pyr s r c C dd t D S )z!Return all existing interpreters.c S s g | ]}t |qS r )r ).0r r r r
s zlist_all..)r r
r r r r r
s r
c C t } t| S )z)Return the currently running interpreter.)r r r r r r r r ! r c C r )zReturn the main interpreter.)r r r r r r r r ' r r c @ sl e Zd ZdZddddZdd Zdd Zd
d Zedd
Z edd Z
dd Zdd ZddddZ
dS )r zA single Python interpreter.Nr c C s. t |ttjfstd||| _|| _d S Nzid must be an int, got )
isinstanceintr
InterpreterID TypeError_id _isolated)selfr r r r r __init__0 s
zInterpreter.__init__c C sB t t| j| jd}dd | D }t| j dd| dS )N)r r c s s" | ]\}}| d |V qdS )=Nr )r kvr r r 8 s z'Interpreter.__repr__..(z, ))dictr r r! itemstype__name__join)r" datakwargsr r r __repr__6 s zInterpreter.__repr__c C
t | jS Nhashr r" r r r __hash__;
zInterpreter.__hash__c C s t |tstS |j| jkS r3 )r r NotImplementedr r" otherr r r __eq__> s
zInterpreter.__eq__c C | j S r3 r r6 r r r r D zInterpreter.idc C s | j d u rt| j| _ | j S r3 )r! r is_isolatedr r6 r r r r H s
zInterpreter.isolatedc C t | jS )z