R-nvim / R.nvim

Neovim plugin to edit R files
GNU General Public License v3.0
155 stars 16 forks source link

Optimize subsetting replacement withing the same node #215

Closed PMassicotte closed 1 month ago

PMassicotte commented 1 month ago

Fix making multiple replacements within the same node, which caused the positions of subsequent replacements to shift, resulting in incorrect text replacements.

For example:

v[a$a, b$b]

Was transformed into:

v[a[["a"[["]"]], b$b]
jalvesaq commented 1 month ago

Thanks!