Bug Report T987846
Visible to All Users

Formatting - A class member with an attribute is incorrectly indented

created 4 years ago

Hello,

If I cleanup this code:

C#
public class Test { [XmlAttribute] public string Something { get; set; } }

I get:

C#
public class Test { [XmlAttribute] public string Something { get; set; } }

Using default settings.

Answers approved by DevExpress Support

created 4 years ago

We have addressed the issue described in this ticket and will include a fix in our next maintenance update. Should you need to apply our fix prior to official release, you can request a hotfix here.

Note: Hotfixes may be unavailable for betas/updates set for release within a week.

    created 4 years ago

    Hi Simon,

    I tried to reproduce this issue locally on a clean machine with default settings, but my attempts were unsuccessful (see the attached video).
    Could you please send us your settings folder located in the %appdata%\CodeRush\Settings folder?

    I'm looking forward to your reply.

      Comments (2)

        That's odd - I tried to reset settings just before using cleanup to make sure its not related but it didn't helped. Only cleaning Settings directory fixes it but I'm loosing my settings. Then after importing my setting zip file the issue is back. Here it is.

        //edit

        I've been able to narrow it to file "Code Cleanup.xml"

        //edit

        "Format document" is the issue… I don't get it.

        DevExpress Support Team 4 years ago

          Thank you for the clarification.
          I have reproduced this issue with your settings.
          The problem lies in our formatting engine. We will notify you when it is fixed.
          Currently, you can turn off the formatting option on the Code Cleanup options page:

          Clipboard-File-1.png

          Disclaimer: The information provided on DevExpress.com and affiliated web properties (including the DevExpress Support Center) is provided "as is" without warranty of any kind. Developer Express Inc disclaims all warranties, either express or implied, including the warranties of merchantability and fitness for a particular purpose. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.

          Confidential Information: Developer Express Inc does not wish to receive, will not act to procure, nor will it solicit, confidential or proprietary materials and information from you through the DevExpress Support Center or its web properties. Any and all materials or information divulged during chats, email communications, online discussions, Support Center tickets, or made available to Developer Express Inc in any manner will be deemed NOT to be confidential by Developer Express Inc. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.