View unanswered posts | View active topics


Reply to topic  [ 5 posts ] 
Vector of vectors causing auto-completion to stop working 
Author Message
Member

Joined: Sat Aug 23, 2008 12:11 am
Posts: 32
Post Vector of vectors causing auto-completion to stop working
Hello,

When I have a member variable that is a Vector of Vectors, auto-completion no longer completes for all member variables/methods. Here is the code:
Code:
package
{
   import flash.display.Sprite;
   import flash.events.Event;
   
   /**
    * ...
    * @author DefaultUser (Tools -> Custom Arguments...)
    */
   public class Main extends Sprite
   {
      // when you enter the semicolon or press enter after the following
      // declaration, FlashDevelop adds extra spaces between the "." and "<"
      // this causes a syntax error
      private var vector:Vector.< Vector.<int> >;
      
      public function Main():void
      {
         if (stage) init();
         else addEventListener(Event.ADDED_TO_STAGE, init);
      }
      
      private function init(e:Event = null):void
      {
         var last:int;
         removeEventListener(Event.ADDED_TO_STAGE, init);
         // entry point
         vector = new Vector.<Vector.<int> >;
         
         last = vector.push(new Vector.<int>);
         last--;
         vector[last].push(1);
         vector[last].push(2);
         
         last = vector.push(new Vector.<int>);
         last--;
         vector[last].push(3);
         vector[last].push(4);
         vector[last].push(5);
         
         ///////////////////////////////////////////////////////
         // FlashDevelop does not auto-complete on any of these!
         ///////////////////////////////////////////////////////
         print();
         dummyFunction();
      }

      // auto-Complete doesn't work for this
      private function dummyFunction():void
      {
         
      }

      // auto-Complete doesn't work for this, either
      private function print():void
      {
         var row:Vector.<int>;
         var num:int;
         
         for each (row in vector)
         {
            for each (num in row)
               trace(num);
         }
      }
   }
   
}


As noted above, when I enter "d" or "p," FlashDevelop does not give me a selection of any methods. When I use a simple Vector, auto-completion works fine.
A minor issue, as noted above, is that FlashDevelop adds spaces in Vector declarations, which causes a compilation error.

I am using r217 of 3.0.0, .Net 2.0, Windows 2000 SP 4.

Thanks.


Mon Dec 01, 2008 2:16 am
Profile
Member

Joined: Sat Aug 23, 2008 12:11 am
Posts: 32
Post Re: Vector of vectors causing auto-completion to stop working
This isn't the show stopping bug that I thought it was. When I enter the following declaration and press enter or the semi-colon button,
Code:
private var nums:Vector.<Vector.<int> >;


it is transformed by FlashDevelop into:
Code:
private var nums:Vector. < Vector. < int > > ;


which does not compile but auto-completion to work. The first declaration, although compiles, throws off FlashDevelop and auto-completion no longer works for member variables/methods and local variables. However, the following declaration compiles:
Code:
private var nums:Vector.< Vector.< int > > ;


and auto-completion works, almost. I say almost, because the following expression does not auto-complete:
Code:
nums[0].push(6);


A menu with the available methods for the Vector nums[0] does not come up.


Mon Dec 01, 2008 3:12 am
Profile
Admin

Joined: Wed Aug 31, 2005 7:27 am
Posts: 10745
Location: Paris, France
Post Re: Vector of vectors causing auto-completion to stop working
Fixed in SVN, except for Vectors of Vectors code completion (TODO).


Tue Dec 09, 2008 3:25 pm
Profile WWW
Member

Joined: Thu Jul 30, 2009 9:54 pm
Posts: 13
Post Re: Vector of vectors causing auto-completion to stop workin
Has the auto-completion on Vectors of Vectors TODO been implemented yet?

Currently doesn't seem to be working with the latest FD I have installed (version details below.)

A couple of examples:

private var things:Vector.<Thing>;
Typing things[0]. DOES auto-complete with members of Thing

private var things:Vector.<Vector.<Thing>>;
Typing things[0][0]. DOES NOT auto-complete with members of Thing

I'm running FlashDevelop 4.0.1 RTM for Microsoft.NET 2.0 (R2198) with Windows XP SP3.

Information from IE: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident 4.0; InfoPath.1; .NET CLR 2.0.50727; .NET CLR 3.0.4056.2152; .NET CLR 3.5.30729; .NET4.0C; .NET CLR 1.1.4322)

Don't currently have access to any other OS to test against.


Sat Apr 07, 2012 9:56 am
Profile
Admin

Joined: Wed Aug 31, 2005 7:27 am
Posts: 10745
Location: Paris, France
Post Re: Vector of vectors causing auto-completion to stop workin
No it's not yet implemented - and not a priority compared to other issues.


Sat Apr 07, 2012 10:57 am
Profile WWW
Display posts from previous:  Sort by  
Reply to topic   [ 5 posts ] 

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

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