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

Variable declared as "var" generate errors

3 Answers 69 Views
Code Analysis
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Sergey
Top achievements
Rank 1
Sergey asked on 06 May 2011, 03:44 PM
You get an error "unknown type of variable" when a variable declared as var and JustCode cannot recognize any methods of that class in the code block.  As a result, I got dozens of errors in my code file for no reason.  Seems like a pretty critical shortcuming to me.
Thanks.

I am using hte latest build as of this morning.


Sergey

3 Answers, 1 is accepted

Sort by
0
Svetlozar
Telerik team
answered on 12 May 2011, 08:21 AM
Hi Sergey,

Thank you for your feedback and sorry for the inconvenience. Could you please send us a simple solution, demonstrating the problem. We use the latest version ourselves and we also have a lot of var usages in our code, but we haven't found any issues like the one you described. There might be something specific in your solution, the way you reference the entities or anything.. 

We will really appreciate if you can provide a sample.

Thank you in advance for the assistance.

Kind regards,
Svetlozar Angelov
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
0
Rick de Vries
Top achievements
Rank 1
answered on 03 Jun 2011, 08:49 AM
Hi,

I'm also running into this problem with JustCode. My applications use a lot of LINQ queries that use alot of untyped variables like q.Where(o => o.Name == "foo"). It's a valid expression but JustCode doesn't like it.

Rick
0
Svetlozar
Telerik team
answered on 09 Jun 2011, 09:29 AM
Hello Rick de Vries,

There must be something specific that we have missed to handle in your code (we use linq queries ourselves).  We consider Good-Code-Reds highly critical, so please, send us Good-Code-Reports whenever you find a wrong error reported by JustCode.

Kind regards,
Svetlozar Angelov
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
Code Analysis
Asked by
Sergey
Top achievements
Rank 1
Answers by
Svetlozar
Telerik team
Rick de Vries
Top achievements
Rank 1
Share this question
or