mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-01-15 20:26:04 +07:00
fixed PY-9654 Make function from method/Make method static: correctly update class calls with first instance argument
This commit is contained in:
@@ -0,0 +1,6 @@
|
||||
__author__ = 'ktisha'
|
||||
|
||||
class A:
|
||||
def fo<caret>o(self):
|
||||
print("Hello Pycharm!")
|
||||
|
||||
@@ -0,0 +1,6 @@
|
||||
class A:
|
||||
def m<caret>(self, x):
|
||||
return x
|
||||
|
||||
|
||||
print A.m(A(), 1)
|
||||
@@ -0,0 +1,3 @@
|
||||
import test
|
||||
|
||||
test.A().foo(1)
|
||||
@@ -0,0 +1,3 @@
|
||||
import test
|
||||
|
||||
test.A().foo(1)
|
||||
@@ -0,0 +1,7 @@
|
||||
class A:
|
||||
@staticmethod
|
||||
def m(x):
|
||||
return x
|
||||
|
||||
|
||||
print A.m(1)
|
||||
Reference in New Issue
Block a user