module documentation
(source)

Undocumented

Function infer​_pattern​_match Infer re.Pattern and re.Match as classes. For PY39+ add __class_getitem__.
Constant CLASS​_GETITEM​_TEMPLATE Undocumented
Function _looks​_like​_pattern​_or​_match Check for re.Pattern or re.Match call in stdlib.
Function _re​_transform Undocumented
def infer_pattern_match(node, ctx=None): (source)
Infer re.Pattern and re.Match as classes. For PY39+ add __class_getitem__.
Parameters
node:nodes.CallUndocumented
ctx:Optional[context.InferenceContext]Undocumented
CLASS_GETITEM_TEMPLATE: str = (source)

Undocumented

Value
'''
@classmethod
def __class_getitem__(cls, item):
    return cls
'''
def _looks_like_pattern_or_match(node): (source)

Check for re.Pattern or re.Match call in stdlib.

Match these patterns from stdlib/re.py `py Pattern = type(...) Match = type(...) `

Parameters
node:nodes.CallUndocumented
Returns
boolUndocumented
def _re_transform(): (source)

Undocumented