File: //snap/core20/2599/usr/lib/python3/dist-packages/jinja2/__pycache__/utils.cpython-38.pyc
U
��g�Q � @ s. d Z ddlZddlZddlZzddlmZ W n ddlmZ Y nX ddlmZ ddl m
Z
mZmZm
Z
ddlmZ ddlmZ edd d
dd� i�� Ze� Zd
jZde�d�kZdd� Zdd� Zdd� Zdd� Zdd� Zdd� Z dd� Z!dCdd �Z"dDd"d#�Z#d$d%� Z$dEd&d'�Z%dFd(d)�Z&dGd.d/�Z'dHd1d2�Z(G d3d4� d4e)�Z*zdd5lm+Z+ e+�,e*� W nH e-k
�r� zdd5lm+Z+ e+�,e*� W n e-k
�r� Y nX Y nX dId7d8�Z.dJd9d:�Z/eG d;d<� d<e)��Z0G d=d>� d>e)�Z1G d?d@� d@e)�Z2ze3dA� d+Z4W n e5k
�r dZ4Y nX ddBl6m7Z7m8Z8m9Z9 dS )Kz�
jinja2.utils
~~~~~~~~~~~~
Utility functions.
:copyright: (c) 2017 by the Jinja Team.
:license: BSD, see LICENSE for more details.
� N)�deque)�Lock)� text_type�string_types�implements_iterator� url_quote)�
ascii_letters)�digitsZMissingType� �__repr__c C s dS )N�missingr
)�xr
r
�./usr/lib/python3/dist-packages/jinja2/utils.py�<lambda> � r � z\/�/c C s
d| _ | S )a+ This decorator can be used to mark a function or method context callable.
A context callable is passed the active :class:`Context` as first argument when
called from the template. This is useful if a function wants to get access
to the context or functions provided on the context object. For example
a function that returns a sorted list of template variables the current
template exports could look like this::
@contextfunction
def get_exported_names(context):
return sorted(context.exported_vars)
T)�contextfunction��fr
r
r r '