Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
User name:
Password:
Save Password
Forgot your password?

 All Forums
 Visual Assist
 Technical Support
 VAX 1535: coloring error with as/is
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

Uniwares
Tomato Guru

Portugal
2321 Posts

Posted - Oct 03 2006 :  2:14:09 PM  Show Profile  Reply with Quote
VS2005, C#

When using the C# keywords as or is, the variable preceeding the keyword is colored wrong.

example:
void buttonX_Click(object sender, EventArg e)
{
  Button X = sender as Button;
  if(sender is Button)
     whatever();
}


Obs: basically whenever you start typing after a variable with a space, the variable will be colored wrong, like in nVarX = nVarY typesomethinghere;

feline
Whole Tomato Software

United Kingdom
18939 Posts

Posted - Oct 04 2006 :  6:18:36 PM  Show Profile  Reply with Quote
i see the same thing with your function.

case=2856

are you seeing this in other cases, that do not involve the "as" or "is" keywords?

using the very basic, and slightly silly test:

int foo;
foo = sender + 2;


VA colours both instances of the variable as a variable rather than a type.

zen is the art of being at one with the two'ness

Edited by - feline on Oct 04 2006 6:23:31 PM
Go to Top of Page

Uniwares
Tomato Guru

Portugal
2321 Posts

Posted - Oct 04 2006 :  7:03:43 PM  Show Profile  Reply with Quote
Not seen it in any other cases, but i guess that the parser simply sees two words, so according to the parsing rules the first one cant be a variable.
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
© 2023 Whole Tomato Software, LLC Go To Top Of Page
Snitz Forums 2000