Fix to SF bug #414743 based on Michael Hudson's patch #414750.
f() keywords must be strings
h() got an unexpected keyword argument 'e'
h() argument after * must be a sequence
+dir() argument after * must be a sequence
+None object argument after * must be a sequence
h() argument after ** must be a dictionary
+dir() argument after ** must be a dictionary
+None object argument after ** must be a dictionary
+dir() got multiple values for keyword argument 'b'
3 512 1
3
3
else:
print "should raise TypeError: * argument must be a tuple"
+try:
+ dir(*h)
+except TypeError, err:
+ print err
+else:
+ print "should raise TypeError: * argument must be a tuple"
+
+try:
+ None(*h)
+except TypeError, err:
+ print err
+else:
+ print "should raise TypeError: * argument must be a tuple"
+
try:
h(**h)
except TypeError, err:
else:
print "should raise TypeError: ** argument must be a dictionary"
+try:
+ dir(**h)
+except TypeError, err:
+ print err
+else:
+ print "should raise TypeError: ** argument must be a dictionary"
+
+try:
+ None(**h)
+except TypeError, err:
+ print err
+else:
+ print "should raise TypeError: ** argument must be a dictionary"
+
+try:
+ dir(b=1,**{'b':1})
+except TypeError, err:
+ print err
+else:
+ print "should raise TypeError: dir() got multiple values for keyword argument 'b'"
+
def f2(*a, **b):
return a, b