3
T'ícéQ ã @ s¸ U d Z ddlZddlZddlmZ ddlmZ ddlmZ ddlmZ ddl m
Z
mZmZm
Z
mZmZmZmZmZmZmZmZ ddlZddlmZ dd lmZ dd
lmZmZmZ ddlmZm Z m!Z! ddl"m#Z# dd
l$m%Z%m&Z&m'Z' ddl(m)Z)m*Z* ddl+m,Z, ddl-m.Z. ddl/m0Z0m1Z1 ddl2m3Z3 ddl4m5Z5 e3j6e7Z8ej9dZ:ertddl;m<Z< ddl=m>Z> ddl?m@Z@ e,jAejBjCZDeE ZFeee FeedY dddZGeHeIdddZJeHee dddd ZKeHeIdd!d"ZLeHe5dd#d$d%ZMeHddd&d'ZNee eId(d)d*ZOee dd(d+d,ZPee dd(d-d.ZQeedZ dd/d0ZReed[ dd1d2ZSeeeH ed\ d3d4d5ZTed]eeH ed^ d3d6d7ZUG d8d9 d9ZVG d:d; d;eWZXG d<d= d=eVZYG d>d? d?ZZG d@dA dAe)Z[G dBdC dCe)Z\eIddDdEZ]ee%e'ed_ dFdGdHZ^G dIdJ dJeZ_G dKdL dLeZ`G dMdN dNZaG dOdP dPeaZbG dQdR dRejcZdeDd`k rdTdU Zeeee_edafeejg fdaeHeejgdVdWdXZhdS )bzUtility functions for docutils.é N)Úcontextmanager)Úcopy)Úpath)Ú
ModuleType)ÚIOÚ
TYPE_CHECKINGÚAnyÚCallableÚDictÚ GeneratorÚListÚOptionalÚSetÚTupleÚTypeÚcast)Únodes)Ú
FileOutput)ÚElementÚNodeÚsystem_message)Ú DirectiveÚ
directivesÚroles)ÚInliner)ÚStateÚStateMachineÚ
StringList)ÚReporterÚunescape)Úversion)ÚSphinxError)Ú_Ú__)Úlogging)ÚRoleFunctionz>^(.+?:(?:\d+)?): \((DEBUG|INFO|WARNING|ERROR|SEVERE)/(\d+)?\) )ÚBuilder)ÚConfig)ÚBuildEnvironment)Úreturnc c sV zt tj} t tj}dV W d| t_|t_x"ttD ]}t| tj| q6W X dS )z"Create namespace for reST parsers.N) r r Ú_directivesr Ú_rolesÚlistÚadditional_nodesÚunregister_nodeÚdiscard)r* r+ Únode© r1 ú6/tmp/pip-build-gk9425m9/sphinx/sphinx/util/docutils.pyÚdocutils_namespace( s
r3 )Únamer) c C s