Skip to content

Update R syntax#647

Merged
Ikuyadeu merged 2 commits intoREditorSupport:masterfrom
renkun-ken:r-4.1
May 31, 2021
Merged

Update R syntax#647
Ikuyadeu merged 2 commits intoREditorSupport:masterfrom
renkun-ken:r-4.1

Conversation

@renkun-ken
Copy link
Copy Markdown
Member

What problem did you solve?

Closes #646

(If you do not have screenshot) How can I check this pull request?

  1. Put cursor on any point of the following code and send code to terminal should send the whole pipeline to terminal.
1:10 |>
  sapply(\(x) x^2) |>
  sum()

@renkun-ken renkun-ken requested review from Ikuyadeu and andycraig May 27, 2021 02:24
@renkun-ken
Copy link
Copy Markdown
Member Author

TBH I'm not quite familiar with the syntax file. Could you please point out if I don't do it right? @andycraig @Ikuyadeu

@Ikuyadeu
Copy link
Copy Markdown
Member

OK, I'll check this weekend.
And, I'll try to make the test code for CI check.

@renkun-ken
Copy link
Copy Markdown
Member Author

Should we do anything about the pipe-bind operator (=>) which is disabled by default unless environment variable _R_USE_PIPEBIND_ is set to a true value?

@ElianHugh
Copy link
Copy Markdown
Collaborator

Maybe for future proofing? Depends on whether the pipe bind operator is going to stay or not - this would lead me to believe it is, but then this twitter thread seems to go against that.

@Ikuyadeu
Copy link
Copy Markdown
Member

Ikuyadeu commented May 31, 2021

@renkun-ken
OK, I checked the code. Thank you!
But testing CI is a bit hard now. So, I merge this once.

And, => should be let now, for confusing replacement. I think users should set that manually.
We can make voting if some users make a new issue about it.

@Ikuyadeu Ikuyadeu merged commit 6f3e0fb into REditorSupport:master May 31, 2021
@renkun-ken
Copy link
Copy Markdown
Member Author

renkun-ken commented May 31, 2021

Do you encounter that most highlighting is lost with the latest release installed?

@renkun-ken
Copy link
Copy Markdown
Member Author

Looks like https://github.com/Ikuyadeu/vscode-R/pull/647/files#diff-f6f05bbc187255f5cf06a39e3a4f7befa7288489c5fd44bb14586143076ffd1dR407-R447 is somehow problematic. I remove that code and the highlighting goes back to normal.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Native pipe operator |> support

3 participants