8000 More argumentless (py3) super() · matplotlib/matplotlib@cb2930a · GitHub
[go: up one dir, main page]

Skip to content

Commit cb2930a

Browse files
committed
More argumentless (py3) super()
1 parent 180639b commit cb2930a

File tree

3 files changed

+4
-10
lines changed

3 files changed

+4
-10
lines changed

lib/matplotlib/backends/backend_gtk3.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -604,8 +604,7 @@ def __init__ (self,
604604
filetypes = [],
605605
default_filetype = None
606606
):
607-
super (FileChooserDialog, self).__init__ (title, parent, action,
608-
buttons)
607+
super().__init__(title, parent, action, buttons)
609608
self.set_default_response (Gtk.ResponseType.OK)
610609

611610
if not path: path = os.getcwd() + os.sep

lib/mpl_toolkits/axes_grid1/mpl_axes.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ def __getitem__(self, k):
3232
if isinstance(k, tuple):
3333
r = SimpleChainedObjects(
3434
[super(Axes.AxisDict, self).__getitem__(k1) for k1 in k])
35+
# super() within a list comprehension needs explicit args
3536
return r
3637
elif isinstance(k, slice):
3738
if k.start is None and k.stop is None and k.step is None:

lib/mpl_toolkits/axisartist/axislines.py

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -207,18 +207,12 @@ def get_tick_transform(self, axes):
207207

208208
return trans_tick
209209

210-
211210
class Floating(_Base):
212-
def __init__(self, nth_coord,
213-
value):
214211

212+
def __init__(self, nth_coord, value):
215213
self.nth_coord = nth_coord
216-
217214
self._value = value
218-
219-
super(AxisArtistHelper.Floating,
220-
self).__init__()
221-
215+
super().__init__()
222216

223217
def get_nth_coord(self):
224218
return self.nth_coord

0 commit comments

Comments
 (0)
0