File: D:/Python311/Lib/test/__pycache__/test_positional_only_arg.cpython-311.opt-2.pyc
�
��Vc�H � � � d dl Z d dlZd dlZd dlmZ d� Zd� Zdd�Z G d� d ej � � Z e
d
k r ej � � dS dS )� N��check_syntax_errorc �
� | |fS �N� ��a�bs �1D:\Python311\Lib\test\test_positional_only_arg.py�global_pos_only_fr
� � ��a�4�K� c �
� | |fS r r r s r �global_pos_only_and_normalr
r
r � � c �
� | |fS r r r s r �global_pos_only_defaultsr r
r c � � e Zd Zd d�Zd� Zd� Zd� Zd� Zd� Zd� Z d � Z
d
� Zd� Zd� Z
d
� Zd� Zd� Zd� Zd� Zd� Zd� Zd� Zd� Zd� Zd� Zd� Zd� Zd� Zd� Zd� Zd� Zd� ZdS )!�PositionalOnlyTestCase�invalid syntaxc � � | � t |� � 5 t |dz dd� � d d d � � d S # 1 swxY w Y d S )N�
�<test>�single)�assertRaisesRegex�SyntaxError�compile)�self�codestr�regexs r �assertRaisesSyntaxErrorz.PositionalOnlyTestCase.assertRaisesSyntaxError s� � �
�
#�
#�K��
7�
7� 8� 8��G�d�N�H�h�7�7�7� 8� 8� 8� 8� 8� 8� 8� 8� 8� 8� 8� 8���� 8� 8� 8� 8� 8� 8s �>�A�Ac �r � t | dd� � t | dd� � t | dd� � t | dd� � t | d� � t | d� � t | d� � t | d � � t | d
� � t | d� � t | d� � t | d
� � t | dd� � t | dd� � t | d� � t | d� � t | d� � t | d� � t | d� � d S )Nzdef f(a, b = 5, /, c): pass�-non-default argument follows default argumentzdef f(a = 5, b, /, c): passz%def f(a = 5, b=1, /, c, *, d=2): passzdef f(a = 5, b, /): passzdef f(*args, /): passzdef f(*args, a, /): passzdef f(**kwargs, /): passzdef f(/, a = 1): passzdef f(/, a): passzdef f(/): passzdef f(*, a, /): passzdef f(*, /, a): passzdef f(a, /, a): pass�-duplicate argument 'a' in function definitionzdef f(a, /, *, a): passzdef f(a, b/2, c): passzdef f(a, /, c, /): passzdef f(a, /, c, /, d): passz def f(a, /, c, /, d, *, e): passzdef f(a, *, c, /, d, e): passr �r s r �test_invalid_syntax_errorsz1PositionalOnlyTestCase.test_invalid_syntax_errors s] � ��4�!>�@o�p�p�p��4�!>�@o�p�p�p��4�!H�Jy�z�z�z��4�!;�=l�m�m�m��4�!8�9�9�9��4�!;�<�<�<��4�!;�<�<�<��4�!8�9�9�9��4�!4�5�5�5��4�!1�2�2�2��4�!7�8�8�8��4�!7�8�8�8��4�!7�9h�i�i�i��4�!:�<k�l�l�l��4�!9�:�:�:��4�!:�;�;�;��4�!=�>�>�>��4�!C�D�D�D��4�!@�A�A�A�A�Ar c �r � t | dd� � t | dd� � t | dd� � t | dd� � t | d� � t | d� � t | d� � t | d � � t | d
� � t | d� � t | d� � t | d
� � t | dd� � t | dd� � t | d� � t | d� � t | d� � t | d� � t | d� � d S )Nz!async def f(a, b = 5, /, c): passr$ z!async def f(a = 5, b, /, c): passz(async def f(a = 5, b=1, /, c, d=2): passzasync def f(a = 5, b, /): passzasync def f(*args, /): passzasync def f(*args, a, /): passzasync def f(**kwargs, /): passzasync def f(/, a = 1): passzasync def f(/, a): passzasync def f(/): passzasync def f(*, a, /): passzasync def f(*, /, a): passzasync def f(a, /, a): passr% zasync def f(a, /, *, a): passzasync def f(a, b/2, c): passzasync def f(a, /, c, /): passz async def f(a, /, c, /, d): passz&async def f(a, /, c, /, d, *, e): passz#async def f(a, *, c, /, d, e): passr r&