@@ -123,10 +123,10 @@ class FreeVar(_Variable):
123
123
124
124
def _check_arg_int (name , arg ):
125
125
if not isinstance (arg , int ):
126
- raise TypeError ("operation %s argument must be an int, " " got %s" % (name , type (arg ).__name__ ))
126
+ raise TypeError ("operation %s argument must be an int, got %s" % (name , type (arg ).__name__ ))
127
127
128
128
if not (0 <= arg <= 2147483647 ):
129
- raise ValueError ("operation %s argument must be in " " the range 0..2,147,483,647" % name )
129
+ raise ValueError ("operation %s argument must be in the range 0..2,147,483,647" % name )
130
130
131
131
132
132
if sys .version_info < (3 , 8 ):
@@ -169,7 +169,7 @@ def __init__(self, name, arg=UNSET, *, lineno=None, offset=None):
169
169
def _check_arg (self , name , opcode , arg ):
170
170
if name == "EXTENDED_ARG" :
171
171
raise ValueError (
172
- "only concrete instruction can contain EXTENDED_ARG, " " highlevel instruction can represent arbitrary argument without it"
172
+ "only concrete instruction can contain EXTENDED_ARG, highlevel instruction can represent arbitrary argument without it"
173
173
)
174
174
175
175
if opcode >= _opcode .HAVE_ARGUMENT :
@@ -181,25 +181,25 @@ def _check_arg(self, name, opcode, arg):
181
181
182
182
if self ._has_jump (opcode ):
183
183
if not isinstance (arg , (Label , _bytecode .BasicBlock )):
184
- raise TypeError ("operation %s argument type must be " " Label or BasicBlock, got %s" % (name , type (arg ).__name__ ))
184
+ raise TypeError ("operation %s argument type must be Label or BasicBlock, got %s" % (name , type (arg ).__name__ ))
185
185
186
186
elif opcode in _opcode .hasfree :
187
187
if not isinstance (arg , (CellVar , FreeVar )):
188
- raise TypeError ("operation %s argument must be CellVar " " or FreeVar, got %s" % (name , type (arg ).__name__ ))
188
+ raise TypeError ("operation %s argument must be CellVar or FreeVar, got %s" % (name , type (arg ).__name__ ))
189
189
190
190
elif opcode in _opcode .haslocal or opcode in _opcode .hasname :
191
191
if not isinstance (arg , str ):
192
- raise TypeError ("operation %s argument must be a str, " " got %s" % (name , type (arg ).__name__ ))
192
+ raise TypeError ("operation %s argument must be a str, got %s" % (name , type (arg ).__name__ ))
193
193
194
194
elif opcode in _opcode .hasconst :
195
195
if isinstance (arg , Label ):
196
- raise ValueError ("label argument cannot be used " " in %s operation" % name )
196
+ raise ValueError ("label argument cannot be used in %s operation" % name )
197
197
if isinstance (arg , _bytecode .BasicBlock ):
198
- raise ValueError ("block argument cannot be used " " in %s operation" % name )
198
+ raise ValueError ("block argument cannot be used in %s operation" % name )
199
199
200
200
elif opcode in _opcode .hascompare :
201
201
if not isinstance (arg , Compare ):
202
- raise TypeError ("operation %s argument type must be " " Compare, got %s" % (name , type (arg ).__name__ ))
202
+ raise TypeError ("operation %s argument type must be Compare, got %s" % (name , type (arg ).__name__ ))
203
203
204
204
elif opcode >= _opcode .HAVE_ARGUMENT :
205
205
_check_arg_int (name , arg )
0 commit comments