IDEA-CR-49176: inline function doesn't copy docstring, but keeps the first-line comment (PY-36469, PY-36491)

GitOrigin-RevId: db1fbb5178892db955678dfcec684a5af7f987c6
This commit is contained in:
Aleksei Kniazev
2019-06-22 15:46:38 +03:00
committed by intellij-monorepo-bot
parent af8d542c7d
commit 72e24eef45
6 changed files with 51 additions and 3 deletions

View File

@@ -0,0 +1,9 @@
def foo():
# comment on the first line
print(42)
return 42
# comment on the first line
print(42)
res = 42

View File

@@ -0,0 +1,7 @@
def foo():
# comment on the first line
print(42)
return 42
res = fo<caret>o()

View File

@@ -0,0 +1,11 @@
def foo():
"""
Docstring for the function
:return: int
"""
print(42)
return 42
print(42)
res = 42

View File

@@ -0,0 +1,10 @@
def foo():
"""
Docstring for the function
:return: int
"""
print(42)
return 42
res = fo<caret>o()