mirror of
https://github.com/davidhalter/jedi.git
synced 2025-12-09 23:34:45 +08:00
Implement inline refactorings
This commit is contained in:
@@ -1,20 +1,28 @@
|
||||
# -------------------------------------------------- simple-1
|
||||
# -------------------------------------------------- simple
|
||||
def test():
|
||||
#? 4
|
||||
a = (30 + b, c) + 1
|
||||
return test(100, a)
|
||||
# ++++++++++++++++++++++++++++++++++++++++++++++++++
|
||||
def test():
|
||||
#? 4
|
||||
return test(100, (30 + b, c) + 1)
|
||||
|
||||
|
||||
# -------------------------------------------------- simple-2
|
||||
--- /home/dave/source/jedi/test/refactor/inline.py
|
||||
+++ /home/dave/source/jedi/test/refactor/inline.py
|
||||
@@ -1,5 +1,4 @@
|
||||
def test():
|
||||
#? 4
|
||||
- a = (30 + b, c) + 1
|
||||
- return test(100, a)
|
||||
+ return test(100, (30 + b, c) + 1)
|
||||
# -------------------------------------------------- tuple
|
||||
if 1:
|
||||
#? 4
|
||||
a = 1, 2
|
||||
return test(100, a)
|
||||
# ++++++++++++++++++++++++++++++++++++++++++++++++++
|
||||
if 1:
|
||||
#? 4
|
||||
return test(100, (1, 2))
|
||||
--- /home/dave/source/jedi/test/refactor/inline.py
|
||||
+++ /home/dave/source/jedi/test/refactor/inline.py
|
||||
@@ -1,5 +1,4 @@
|
||||
if 1:
|
||||
#? 4
|
||||
- a = 1, 2
|
||||
- return test(100, a)
|
||||
+ return test(100, (1, 2))
|
||||
|
||||
Reference in New Issue
Block a user