languageserver icon indicating copy to clipboard operation
languageserver copied to clipboard

Autoindent adding unneccesary indent

Open gowerc opened this issue 3 years ago • 2 comments

Describe the bug

If adding pipes onto the end of a command that finishes with a bracket on a newline the autoindent seems to want to add an extra indent.

To Reproduce Steps to reproduce the behavior:

2022-02-03 09 26 36

Do you want to fix by self? (We hope your help!)

No

Expected behavior

That it doesn't indent a second time

Environment (please complete the following information):

OS: macOS
VSCode Version: 1.63.2
R Version: 4.1.2
vscode-R version: v2.3.6

gowerc avatar Feb 03 '22 09:02 gowerc

@renkun-ken is it an issue of auto formatting on typing?

randy3k avatar Feb 03 '22 19:02 randy3k

Yes, it is.

It is caused by how we determine the range of the current expression.

renkun-ken avatar Feb 04 '22 01:02 renkun-ken