About Store Forum Documentation Contact
Donations:
206$/mo



Post Reply 
Autocomplete for local variables
Author Message
aceio76 Offline
Silver Supporter

Post: #1
Autocomplete for local variables
Hi Greg,

I'm not sure if this was always the case, but did the esenthel editor ever included local variables in the autocomplete?

For instance:

class newclass
{
Vec somepoint;

somepoint=VecZero; // <-- typing 'somepoint' will not show it listed in the autocomplete
}
11-13-2016 02:09 AM
Visit this user's website Find all posts by this user Quote this message in a reply
Esenthel Offline
Administrator

Post: #2
RE: Autocomplete for local variables
(11-13-2016 02:09 AM)aceio76 Wrote:  class newclass
{
Vec somepoint;

somepoint=VecZero; // <-- typing 'somepoint' will not show it listed in the autocomplete
}

Yes it should work OK, however in your case, you're not typing this inside a method.

You need to do:
Code:
class Class
{
   int x=0;
}
or
Code:
class Class
{
   int x;
  
   void func()
   {
      x=0;
   }
}
11-13-2016 03:50 AM
Find all posts by this user Quote this message in a reply
aceio76 Offline
Silver Supporter

Post: #3
RE: Autocomplete for local variables
Ah yes you're right, it doesn't make sense to autocomplete when the variable can't be referenced anyway. I don't know why I thought the autocomplete would work if outside of a method smile
11-14-2016 07:36 PM
Visit this user's website Find all posts by this user Quote this message in a reply
Post Reply