Commit Graph

42 Commits

Author SHA1 Message Date
andrey.matveev
5fba7db380 PY-41375 PY-37765 Fix selection problem in PyStatementMover
Also fix unchecked exception in PY-37765

(cherry picked from commit 3b8f3ca228d8e649a63d277314bf13994b80ffd3)

IJ-MR-6623

GitOrigin-RevId: 22026406e912c057bb7d81cb59d7a4e21da6f0f5
2021-04-13 02:42:15 +00:00
Semyon Proshev
56a1c00c2a Make python-latest project descriptor default in tests
Update test data and reduce manual language level setup

GitOrigin-RevId: d6ddec1b2b29a2b7f1a34cfb5982fd975de78d65
2021-03-15 17:33:04 +00:00
andrey.matveev
43f00d7705 PY-41312 Fix moving selected lines with different folding level
(cherry picked from commit a099d7b13c66615bf54aa7bdd5273770de3afaba)

IJ-MR-4314

GitOrigin-RevId: dffaccd88d13ca77cd281a28c46e9d43513a43c6
2021-02-25 10:53:06 +00:00
Mikhail Golubev
f6a325b3de PY-17017 Fix existing test data
The new way to handle trailing line comments that includes them into the
proper block (statement list) depending on their indentation affected
the behavior of "Surround with custom folding region" that previously
either over-indented the closing comment or under-indented it
(see PY-14358). Now these comments always stick to the first column,
since CustomFoldingSurroundDescriptor inserts them without any
indentation at all, and hence they are consistently recognized as
children of the containing PSI file node itself.

Now it's finally possible to fix that issue for good.
2017-10-02 15:20:24 +03:00
Dmitry Batrak
07f1ec121e IDEA-162062 Move Statement: Scope of shifted block changes
fix for Python use cases
2016-10-06 11:52:31 +03:00
Ekaterina Tuzova
7fd1c618c0 fixed PY-11198 Move Statement Up/Down near dictionary expression unexpectedly merges statements 2014-09-08 19:16:48 +04:00
Ekaterina Tuzova
877fae21f2 fixed PY-13868 Move statement on a comment inside a dict deletes the dict 2014-09-08 17:55:30 +04:00
Ekaterina Tuzova
9376c69e6f fixed PY-11654 Move Statement: IOE at com.intellij.openapi.editor.impl.DocumentImpl.d 2013-12-18 17:49:42 +04:00
Ekaterina Tuzova
6d95991c01 fixed PY-11595 Unable to move lines within Python doc strings 2013-12-11 16:26:34 +04:00
Ekaterina Tuzova
193659be87 fixed PY-10947 Moving lines splits multiple statements 2013-10-09 15:53:43 +04:00
Ekaterina Tuzova
01caab85df python: added ability to move multiline statements
fixed PY-6587 Move Statements: inconsistent selection on moving more than one statement up or down.
2013-09-13 20:02:16 +04:00
Ekaterina Tuzova
3be529abb4 fixed test data for move statement 2013-08-26 15:18:03 +04:00
Ekaterina Tuzova
846eed9ad5 added ability to move continue/break/pass 2013-08-26 15:04:20 +04:00
Ekaterina Tuzova
25504900e1 meet brand new python move statement
work over PSI instead of document lines
2013-08-24 17:35:25 +04:00
Ekaterina Tuzova
b48f0896d3 fixed PY-6282 Move statement: adds newline between parts of compound statement 2012-09-20 16:10:49 +04:00
Ekaterina Tuzova
dac294d16f fixed PY-6482 Move statement: ineffective move down to else statement in try/except/else 2012-05-02 15:42:24 +04:00
Ekaterina Tuzova
be137ab0d9 fixed PY-6271 Move statement: breaks code in case of empty line between parts of compound statement 2012-04-10 18:10:06 +04:00
Ekaterina Tuzova
194383cbd0 fixed PY-6133 Move statement: strange comment moving down to def or class statements 2012-04-08 17:12:16 +04:00
Ekaterina Tuzova
b2e3d61ea6 fixed PY-6163 Moving blocks of code 2012-04-06 14:05:13 +04:00
Ekaterina Tuzova
32220e98fa fixed PY-5268 Move statement: breaks code in case of indented one-line compound statements 2012-03-22 17:14:48 +04:00
Ekaterina Tuzova
c4928a6bfc fixed PY-5527 Move statement: unnecessary pass statement on moving one-line comment out of indented block 2012-03-22 15:59:49 +04:00
Ekaterina Tuzova
5caf729b30 fixed PY-5270 Move statement: unexpected move on trying to move one-line comment within indented block 2012-03-22 15:50:31 +04:00
Ekaterina Tuzova
7e1917023d fixed PY-5192 Move Statement: breaks code in case moving down to nested try statement 2012-03-22 14:44:10 +04:00
Ekaterina Tuzova
b4a41273d7 fixed PY-5525 Move statement: loses code on moving one-line comment up to function with nested indent 2012-03-14 12:04:11 +04:00
Ekaterina Tuzova
099e229783 fixed PY-5192 Move Statement: breaks code in case moving down to nested try statement 2011-12-15 14:39:01 +04:00
Ekaterina Tuzova
a1e5d2ea44 fixed PY-5200 Move statement: ineffective moving of nested if block 2011-12-14 16:32:20 +04:00
Ekaterina Tuzova
120efe6cc2 fixed PY-5221 Move statement: Throwable at com.intellij.psi.impl.PsiToDocumentSynchronizer.a 2011-12-05 21:03:39 +04:00
Ekaterina Tuzova
1de2fbaba1 fixed PY-5201 Move statement: changes code logic on moving one-line compound statement outside nested one 2011-12-02 15:57:17 +01:00
Ekaterina Tuzova
a5a774f33b fixed PY-5203 Move statement: statement should not jump into docstring 2011-12-02 15:32:14 +01:00
Ekaterina Tuzova
14d89ce4c6 fixed PY-5202 Move statement: breaks code on moving outside with statement 2011-12-02 15:21:48 +01:00
Ekaterina Tuzova
ef2640a510 fixed PY-5197 Move statement: inconsistent skipping of empty lines 2011-12-02 12:45:03 +01:00
Ekaterina Tuzova
a0b8b18a56 fixed PY-5198 Move statement: breaks code in case of one-line compound statements on module level 2011-12-02 12:19:43 +01:00
Ekaterina Tuzova
3c98006baf fixed PY-5196 Move statement: gets stuck on moving class after compound statement 2011-12-02 12:05:34 +01:00
Ekaterina Tuzova
fbee7c314f fixed PY-5192 Move Statement: breaks code in case moving down to nested try statement 2011-12-02 11:52:05 +01:00
Ekaterina Tuzova
2219082ab8 fixed PY-5193 Move Statement: do not allow to move break and continue statements out of a loop 2011-12-02 11:39:29 +01:00
Ekaterina Tuzova
0c455eb332 fixed PY-5195 Move Statement: loses code on moving nested function 2011-12-02 11:33:55 +01:00
Ekaterina Tuzova
d22ca23963 rewritten move statement for python (see PY-3284, PY-1834, PY-3283) 2011-12-01 22:06:52 +01:00
Dmitry Jemerov
ad885be9fe correct handling of decorators in move statement up/down (PY-1222) 2010-07-17 19:46:51 +04:00
alexey.ivanov
03762a6f9d more improvements for python statement mover 2010-05-11 16:53:06 +04:00
alexey.ivanov
68b2b14abf improved python statement mover 2010-05-07 20:46:38 +04:00
alexey.ivanov
31981b778c fixed PY-950 Exception from Move Statement, more tests 2010-05-07 17:00:39 +04:00
alexey.ivanov
929c46c54b PY-296 'Move statement up/down' on method name line should move the whole method 2010-05-05 22:18:28 +04:00