관리-도구
편집 파일: _compat.cpython-37.pyc
B �:`� � @ s$ d dl mZmZmZ d dlZd dlZd dlZd dlZejd dkZ e� � dkZesdejdd� dkrjeZ nd dlmZ eZ e r�d dlmZmZ d dlmZ d d � Zdd� Zd Zdd� ZG dd� de�Zdd� Zdd� Zn:d dlmZmZ dd� Zdd � ZdZdd� ZejZdd� Zdd� Ze� ZdS )� )�absolute_import�division�print_functionN� �PyPy)� � )�OrderedDict)�Mapping�Sequence)�IterableUserDictc C s t | ttjf�S )N)� isinstance�type�typesZ ClassType)�klass� r �=/opt/alt/python37/lib/python3.7/site-packages/attr/_compat.py�isclass s r c C s i }||� t | ||�S )zP A minimal stub of types.new_class that we need for make_class. )r )�name�bases�kwds� exec_body�nsr r r � new_class s r r c C s | � � S )N)� iteritems)�dr r r r + s r c @ sT e Zd ZdZdd� Zdd� Zdd� Zdd � Zddd�Zd d� Z ddd�Z dd� Zd S )�ReadOnlyDictz5 Best-effort read-only dict wrapper. c C s t d��d S )Nz6'mappingproxy' object does not support item assignment)� TypeError)�self�key�valr r r �__setitem__4 s zReadOnlyDict.__setitem__c C s t d��d S )Nz/'mappingproxy' object has no attribute 'update')�AttributeError)r �_r r r �update: s zReadOnlyDict.updatec C s t d��d S )Nz4'mappingproxy' object does not support item deletion)r )r r# r r r �__delitem__@ s zReadOnlyDict.__delitem__c C s t d��d S )Nz.'mappingproxy' object has no attribute 'clear')r"