This is a migrated thread and some comments may be shown as answers.

Bad, Bad Formatting

5 Answers 76 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Stuart Hemming
Top achievements
Rank 2
Stuart Hemming asked on 03 Mar 2011, 07:01 PM
I have this ...
//***********************************************************************
// Assembly         : xxxxxxxxxxxxx
// Author           : Su
// Created          : 11-29-2010
//
// Last Modified By : Stuart Hemming
// Last Modified On : 25-02-2011
// Description      :
//
// Copyright        : xxxxxxxxxxxxxxxxxxxxx
//***********************************************************************
using System;
using Telerik.Web.UI;
using System.Linq;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI;

Which, once the latest version of JC has had its way, ends up like this...
using System.Linq;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI;
//***********************************************************************
// Assembly         : xxxxxxxxxx
// Author           : Su
// Created          : 11-29-2010
//
// Last Modified By : Stuart Hemming
// Last Modified On : 25-02-2011
// Description      :
//
// Copyright        : xxxxxxxxxxxxxxxxx
//***********************************************************************
using System;
using Telerik.Web.UI;

I can duplicate this at will.

-- 
Stuart

5 Answers, 1 is accepted

Sort by
0
Blagoev
Telerik team
answered on 08 Mar 2011, 02:11 PM
Hi Stuart Hemming,
Thanks for sending the issue. It seems we can't reproduce the problem Can you send us a simple solution witch reproduces the problem and your current JustCode settings. It may be something related to specific settings plus the solution you are working on.

Kind regards,
Blagoev
the Telerik team
Registration for Q1 2011 What’s New Webinar Week is now open. Mark your calendar for the week starting March 21st and book your seat for a walk through all the exciting stuff we ship with the new release!
0
Stuart Hemming
Top achievements
Rank 2
answered on 06 Apr 2011, 05:24 PM
Blagoev,

Please forgive me for taking so long to reply; I lost track of this one.

The problem appears, on closer observation, to be one of timing. Let me explain.

If the block of using statements is in order, the reformatting doesn't cause a problem. You can see JC moving stuff around and sometimes it just puts one or two usings clauses above the comment block and, I think, it believes it has put them in the right place.

The issue doesn't /appear/ to be related to the size of the source file, but it /does/ appear to happen more often if the VS I'm in has been running a while.

-- 
Stuart
0
Stuart Hemming
Top achievements
Rank 2
answered on 07 Apr 2011, 09:09 AM
Also, it /seems/ that if the using block is collapsed, then the problem doesn't occur. At least, it hasn't so far.

-- 
Stuart
0
Stuart Hemming
Top achievements
Rank 2
answered on 07 Apr 2011, 10:14 AM
Blagoev,

I've just downloaded the latest internal build. This version still moves one or 2 lines of using statements above the comment block. Unlike previous versions, though, formatting the file again, immediately afterwards seems to correct the problem; I don;t have to move the mis-places statements myself.

-- 
Stuart
0
Blagoev
Telerik team
answered on 08 Apr 2011, 01:14 PM
Hello Stuart Hemming,
Still we can't reproduce it here. We will stay alert for this kind of problem and see if it emerges in some deterministic scenario.

All the best,
Blagoev
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Tags
General Discussions
Asked by
Stuart Hemming
Top achievements
Rank 2
Answers by
Blagoev
Telerik team
Stuart Hemming
Top achievements
Rank 2
Share this question
or