Match protocol usage against definition to get correct substitutions (PY-13750)

This commit is contained in:
Semyon Proshev
2018-04-23 19:40:17 +03:00
parent d329187a84
commit 5aa26dd020
4 changed files with 35 additions and 1 deletions
@@ -13,4 +13,4 @@ def test_numerics():
divmod(False, False)
divmod(<warning descr="Expected type '_N', got 'bytes' instead">b'foo'</warning>, <warning descr="Expected type '_N', got 'str' instead">'bar'</warning>)
pow(False, True)
round<warning descr="Unexpected type(s):(bool, str)Possible types:(SupportsRound, int)(float, int)">(False, 'foo')</warning>
round<warning descr="Unexpected type(s):(bool, str)Possible types:(SupportsRound[int], int)(float, int)">(False, 'foo')</warning>