Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Completions: Add multi-line heuristics for C, C++, C#, and Java #53631

Merged
merged 2 commits into from
Jun 17, 2023

Conversation

philipp-spiess
Copy link
Contributor

@philipp-spiess philipp-spiess commented Jun 17, 2023

The title says it all. They're all c-like so the implementation doesn't need to change.

I also noticed that we currently do not support this style of syntax for else-block continuation. I don't think it's a big issue though since the single line } would end the selection so it's not as noticible as in the single line case. E.g. compare this cut-off behavior:

This:

if ()
{
  // foo
} 

With this:

if ()
{
  // foo
} else {

And it's clear as to why this is only an issue in the single line case

Test plan

  • Big test coverage this time

@philipp-spiess philipp-spiess requested review from valerybugakov and a team June 17, 2023 08:26
@cla-bot cla-bot bot added the cla-signed label Jun 17, 2023
@github-actions github-actions bot added the team/code-exploration Issues owned by the Code Exploration team label Jun 17, 2023
@sourcegraph-bot
Copy link
Contributor

📖 Storybook live preview

@philipp-spiess philipp-spiess merged commit c6b33a0 into main Jun 17, 2023
22 of 23 checks passed
@philipp-spiess philipp-spiess deleted the ps/completions-langs branch June 17, 2023 09:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cla-signed team/code-exploration Issues owned by the Code Exploration team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants