Fold code #if UNITY_EDITOR

Hi! Is here a way to fold #if UNITY_EDITOR regions, like #region? See screenshot. #if UNITY_EDITOR doesn't have that arrow. 

Before anyone says regions are code smell, I like them :(


Hello Bacall ,

Thank you for contacting Rider Support.

Unfortunately, it looks like you have faced a known issue: RIDER-15391 Cannot Fold Preprocessor Blocks. We would appreciate it if you would upvote it in order to bring increased awareness to the issue. 

Let me know if there is anything else I could help you with. Have a great day!



Hi, thank you for the quick reply! 

Voted on it, but I see it already has 29 votes now, and open for 6 years? Not sure how much more increased awareness I can bring to it. Not meant to come across jeering or snide, in that case I apologize. 

I hope the feature gets added soon, all the best. 


Thank you for the feedback! The ticket is not abandoned, despite the age. We will review the priority of this issue when planning our future development. 


Please sign in to leave a comment.