utils: checkstyle.py: Drop arguments to super() when possible
The super() call is a shortcut syntax for super(__class__, <first arg>). Drop the arguments when they match the default. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Niklas Söderlund <niklas.soderlund@ragnatech.se> Reviewed-by: Paul Elder <paul.elder@ideasonboard.com>
This commit is contained in:
parent
6ef7eddfd4
commit
b402734e5a
1 changed files with 2 additions and 2 deletions
|
@ -198,7 +198,7 @@ _style_checkers = []
|
|||
|
||||
class StyleCheckerRegistry(type):
|
||||
def __new__(cls, clsname, bases, attrs):
|
||||
newclass = super(StyleCheckerRegistry, cls).__new__(cls, clsname, bases, attrs)
|
||||
newclass = super().__new__(cls, clsname, bases, attrs)
|
||||
if clsname != 'StyleChecker':
|
||||
_style_checkers.append(newclass)
|
||||
return newclass
|
||||
|
@ -387,7 +387,7 @@ _formatters = []
|
|||
|
||||
class FormatterRegistry(type):
|
||||
def __new__(cls, clsname, bases, attrs):
|
||||
newclass = super(FormatterRegistry, cls).__new__(cls, clsname, bases, attrs)
|
||||
newclass = super().__new__(cls, clsname, bases, attrs)
|
||||
if clsname != 'Formatter':
|
||||
_formatters.append(newclass)
|
||||
return newclass
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue