-
Notifications
You must be signed in to change notification settings - Fork 250
/
Copy pathoverloads_invalid.toml
47 lines (47 loc) · 3.5 KB
/
overloads_invalid.toml
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
conformant = "Partial"
conformance_automated = "Fail"
notes = """
Does not allow an overload with no implementation in an abstract base class.
"""
errors_diff = """
Line 49: Unexpected errors ['overloads_invalid.py:49: error: An overloaded function outside a stub file must have an implementation [no-overload-impl]']
Line 202: Unexpected errors ['overloads_invalid.py:202: error: Signature of "good_override" incompatible with supertype "Base" [override]']
"""
output = """
overloads_invalid.py:14: error: Single overload definition, multiple required [misc]
overloads_invalid.py:26: error: An overloaded function outside a stub file must have an implementation [no-overload-impl]
overloads_invalid.py:49: error: An overloaded function outside a stub file must have an implementation [no-overload-impl]
overloads_invalid.py:63: error: An overloaded function outside a stub file must have an implementation [no-overload-impl]
overloads_invalid.py:78: error: Overload does not consistently use the "@staticmethod" decorator on all function signatures. [misc]
overloads_invalid.py:88: error: Overloaded function implementation does not accept all possible arguments of signature 1 [misc]
overloads_invalid.py:88: error: Overloaded function implementation does not accept all possible arguments of signature 2 [misc]
overloads_invalid.py:91: error: Overload does not consistently use the "@classmethod" decorator on all function signatures. [misc]
overloads_invalid.py:133: error: @final should be applied only to overload implementation [misc]
overloads_invalid.py:148: error: @final should be applied only to overload implementation [misc]
overloads_invalid.py:176: error: Cannot override final attribute "final_method" (previously declared in base class "Base") [misc]
overloads_invalid.py:176: error: Signature of "final_method" incompatible with supertype "Base" [override]
overloads_invalid.py:176: note: Superclass:
overloads_invalid.py:176: note: @overload
overloads_invalid.py:176: note: def final_method(self, x: int) -> int
overloads_invalid.py:176: note: @overload
overloads_invalid.py:176: note: def final_method(self, x: str) -> str
overloads_invalid.py:176: note: Subclass:
overloads_invalid.py:176: note: def final_method(self, x: int | str) -> int | str
overloads_invalid.py:183: error: Method "bad_override" is marked as an override, but no base method was found with this name [misc]
overloads_invalid.py:202: error: Signature of "good_override" incompatible with supertype "Base" [override]
overloads_invalid.py:202: note: Superclass:
overloads_invalid.py:202: note: def good_override(self, x: int | str) -> int | str
overloads_invalid.py:202: note: Subclass:
overloads_invalid.py:202: note: @overload
overloads_invalid.py:202: note: def good_override(self, x: int) -> int
overloads_invalid.py:202: note: @overload
overloads_invalid.py:202: note: def good_override(self, x: str) -> str
overloads_invalid.py:217: error: Signature of "to_override" incompatible with supertype "Base" [override]
overloads_invalid.py:217: note: Superclass:
overloads_invalid.py:217: note: def to_override(self, x: int | str) -> int | str
overloads_invalid.py:217: note: Subclass:
overloads_invalid.py:217: note: @overload
overloads_invalid.py:217: note: def to_override(self, x: int) -> int
overloads_invalid.py:217: note: @overload
overloads_invalid.py:217: note: def to_override(self, x: str) -> str
"""