File: test38.py

package info (click to toggle)
pychecker 0.8.19-10
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 2,484 kB
  • ctags: 2,114
  • sloc: python: 9,968; sh: 98; makefile: 13
file content (54 lines) | stat: -rw-r--r-- 1,622 bytes parent folder | download | duplicates (9)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
'd'

class X:
    'd'
    def m1(self, a, b, c, d): pass
    def m2(self, a, b, c, d, *args): pass
    def m3(self, a, b, c, d, *args, **kwArgs): pass
    def m4(self, a, b=0, c=0, d=0): pass
    def m5(self, a, b=0, c=0, d=0, *args): pass
    def m6(self, a, b=0, c=0, d=0, *args, **kwArgs): pass

class Y1(X):
    'should not generate any warnings'
    def m1(self, a, b, c, d): exec a in globals()
    def m2(self, a, b, c, d, *args): exec a in globals()
    def m3(self, a, b, c, d, *args, **kwArgs): exec a in globals()
    def m4(self, a, b, c, d): exec a in globals()
    def m5(self, a, b, c, d, *args): exec a in globals()
    def m6(self, a, b, c, d, *args, **kwArgs): exec a in globals()

class Z1(X):
    'should generate warnings'
    def m1(self, a, b, c): pass
    def m2(self, a, b, c, d): pass
    def m3(self, a, b, c, d, **kwArgs): pass
    def m4(self, a, b=0, c=0): pass
    def m5(self, a, b=0, c=0, d=0): pass
    def m6(self, a, b=0, c=0, d=0, **kwArgs): pass

class Z2(X):
    'should generate warnings'
    def m3(self, a, b, c, d, *args): pass
    def m6(self, a, b=0, c=0, d=0, *args): pass

class Z3(X):
    'should generate warnings'
    def m3(self, a, b, c, d): pass
    def m6(self, a, b=0, c=0, d=0): pass

class Z4(X):
    'should generate warnings'
    def m1(self): pass
    def m2(self): pass
    def m3(self): pass
    def m4(self): pass
    def m5(self): pass
    def m6(self): pass

class AAA:
    'should generate 1 warning'
    __pychecker__ = 'exec'
    def m1(self, a, b, c, d): pass
    def m2(self, a, b, c, d, *args): exec a in d
    def m3(self, a, b, c, d, *args): exec a