roslyn icon indicating copy to clipboard operation
roslyn copied to clipboard

Allow collapsing 'case' blocks for switch statements.

Open CyrusNajmabadi opened this issue 6 years ago • 16 comments

CyrusNajmabadi avatar Sep 18 '18 17:09 CyrusNajmabadi

@CyrusNajmabadi Just informing you that respective implementation for (Select Case blocks) are (Issue #8278, PR #27617)

AdamSpeight2008 avatar Sep 18 '18 18:09 AdamSpeight2008

@AdamSpeight2008 Great! Can you roll the C# side of htis into your PR as well?

CyrusNajmabadi avatar Sep 18 '18 18:09 CyrusNajmabadi

Design Meeting Notes Seems like a good idea, We should not collapse the case value itself, but anything under its body should be collapsible.
also see related issue https://github.com/dotnet/roslyn/issues/35792

jinujoseph avatar Jul 01 '19 00:07 jinujoseph

Anyone working on this? I think this is a good feature to have as now I have cases that is super big.

melicaster avatar Feb 06 '20 05:02 melicaster

@melicaster this is still up-for-grabs. Would you happen to be interested in picking it up? 😄

sharwell avatar Feb 06 '20 13:02 sharwell

@melicaster @sharwell Other than the linked pull-request in the first reply?

AdamSpeight2008 avatar Feb 07 '20 12:02 AdamSpeight2008

@AdamSpeight2008 I believe you closed that PR, do you still want to work on this?

jmarolf avatar Feb 07 '20 15:02 jmarolf

@jmarolf To honest I couldn't care less about who implements it, it was I (and the community) have wanted. So I implemented a version. Who implements "the version" don't care.

AdamSpeight2008 avatar Feb 07 '20 15:02 AdamSpeight2008

@AdamSpeight2008 would you be willing to complete that original PR? Someone else could potentially do the C# side (or you could do it if interested). Thanks!

CyrusNajmabadi avatar Feb 07 '20 18:02 CyrusNajmabadi

@AdamSpeight2008 can you let us know what your plans are here? thanks!

CyrusNajmabadi avatar Oct 31 '22 21:10 CyrusNajmabadi

@CyrusNajmabadi It was completed 4 years ago, I moved on. You are someone else can rebase the pull request on the latest branch.

AdamSpeight2008 avatar Nov 02 '22 20:11 AdamSpeight2008

Hello arkalyanms,

What does this mean? I'm sorry but I don't understand. I've raised an issue with Microsoft and ended here. Was the interface changed between 2017 and twas this feature removed in 2020? I don't see any advantage removing the collapse symbols inside each case statement.

Please advise. Many thanks.

Kind regards, ptuga

ptuga avatar Dec 05 '22 21:12 ptuga

@ptuga The interface did not change, but the coding to enable that collapsing of inner symbols (not just case statements) was provided in pull request #27617

AdamSpeight2008 avatar Dec 08 '22 14:12 AdamSpeight2008

@AdamSpeight2008 Hello, sorry for my ignorance on the topic. I'm new on this environment. The pull request 27617 has comments going back to Oct 31, 2018. Does this means the coding to enable the function I reported has been implemented or will be implemented at some point in the future (is it possible to know when)? As far I can experience, this isn't available in Microsoft Visual Studio Community 2022 (64-bit) - Current Version 17.4.1. Could you please clarify? Thank you

ptuga avatar Dec 13 '22 23:12 ptuga

@ptuga Taht PR was abandoned. No work has been done since to enable this feature. We would likely accept a PR from Adam (or you) on this topic if either of you are interested. Thanks!

CyrusNajmabadi avatar Dec 14 '22 01:12 CyrusNajmabadi

Fixed with https://github.com/dotnet/roslyn/pull/66724.

CyrusNajmabadi avatar Feb 10 '23 00:02 CyrusNajmabadi