View unanswered posts | View active topics



Reply to topic  [ 1 post ] 
"\\" treated like the end of the file 
Author Message
Member

Joined: Thu May 14, 2015 6:02 pm
Posts: 45
Reply with quote
One of my classes has been behaving very strangely. Organize Imports would remove almost all of my import statements. Rename and Find All References wouldn't work. It was as though the Code Formatter couldn't see past a certain line in my file. Finally I figured out the line was this:
Code:
path = "\\..\\..\\..\\..\\..\\..\\..\\External Bin\\";


After some experimentation I found that the problem is with the \\" at the end of the string. I could recreate the problem by inserting "\\" in various places, and I found that the problem is fixed when an extra " is put in a comment after the problematic string.

It looks like the parser is treating code as though it's in a string.

I'm using FlashDevelop 5.2.0.3 for .NET 3.5 with Windows 10.

To reproduce this bug, paste the following into an AS3 file and right-click the text editor and click on Refactor > Organize Imports.

Code:
package
{
   import flash.events.Event;
   public class  MyClass
   {
      public function MyClass()
      {
         var s:String = "\\";
         var e:Event;
      }
   }
}


Tue May 02, 2017 1:13 pm
Profile
Display posts from previous:  Sort by  
Reply to topic   [ 1 post ] 

Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by ST Software for PTF.