관리-도구
편집 파일: fix_unicode.cpython-34.pyo
� j f� � @ sW d Z d d l m Z d d l m Z i d d 6d d 6Z Gd d � d e j � Z d S)z�Fixer for unicode. * Changes unicode to str and unichr to chr. * If "...\u..." is not unicode literal change it into "...\\u...". * Change u"..." into "...". � )�token)� fixer_base�chrZunichr�strZunicodec s: e Z d Z d Z d Z � f d d � Z d d � Z � S)� FixUnicodeTzSTRING | 'unicode' | 'unichr'c s/ t t | � j | | � d | j k | _ d S)N�unicode_literals)�superr � start_treeZfuture_featuresr )�selfZtree�filename)� __class__� �>/opt/alt/python34/lib64/python3.4/lib2to3/fixes/fix_unicode.pyr s zFixUnicode.start_treec C s� | j t j k r2 | j � } t | j | _ | S| j t j k r� | j } | j r� | d d k r� d | k r� d j d d � | j d � D� � } n | d d k r� | d d � } n | | j k r� | S| j � } | | _ | Sd S) N� z'"�\z\\c S s. g | ]$ } | j d d � j d d � � q S)z\uz\\uz\Uz\\U)�replace)�.0�vr r r � <listcomp>! s z(FixUnicode.transform.<locals>.<listcomp>ZuU� ) �typer �NAMEZclone�_mapping�value�STRINGr �join�split)r ZnodeZresults�new�valr r r � transform s"