This question is locked. New answers and comments are not allowed.
First one is Linq related, the following code snippet will give a "C#: This cast is not required", but it is ;)
JustCode will note that the typecast (SomeEnum?) is not needed, however removing that type cast will give a "The null value cannot be assigned to a member with type SomeEnum which is a non-nullable type.". (note the above snippet is pseudo code as my actual code wouldnt be much use for you either, but to make it work the childtable should have the field Test and it has to be of the type SomeEnum and the record in sometable has to exist but the record in childtable shouldnt)
One small note, it only seemed to apply to the enumerator, if I type-casted an int to int? it didnt give me the warning.
The other issue is related to this code snippet:
JustCode freaks out on this, my guess is that it incorrectly parses the ContentType (which only indicates the output of the page) thinking that the rest of the page is JavaScript, however the language clearly indicates its C#.
Also a minor issue, one of our old projects still uses 'good' old xsd file (in the app_code folder of a website) for the DAL, JustCode pretty much fails to detect anything defined in there. I'm not even sure if you can still create xsd in VS2008 but its a legacy project.
var result = from somerecord in context.sometable |
select new { Test = (SomeEnum?)somerecord.ChildTable.FirstOrDefault().Test }; |
JustCode will note that the typecast (SomeEnum?) is not needed, however removing that type cast will give a "The null value cannot be assigned to a member with type SomeEnum which is a non-nullable type.". (note the above snippet is pseudo code as my actual code wouldnt be much use for you either, but to make it work the childtable should have the field Test and it has to be of the type SomeEnum and the record in sometable has to exist but the record in childtable shouldnt)
One small note, it only seemed to apply to the enumerator, if I type-casted an int to int? it didnt give me the warning.
The other issue is related to this code snippet:
<%@ Page Language="C#" ContentType="text/javascript" %> |
<%@ Import Namespace="Moxiecode.Manager.Utils"%> |
<% |
string[] classes = Request["classes"].Split(new[] { ',' }); |
var compressor = new JSCompressor(); |
foreach (string file in classes) |
compressor.AddFile(file.ToLower().Replace('.', '/') + ".js"); |
compressor.Compress(Request, Response); |
%> |
JustCode freaks out on this, my guess is that it incorrectly parses the ContentType (which only indicates the output of the page) thinking that the rest of the page is JavaScript, however the language clearly indicates its C#.
Also a minor issue, one of our old projects still uses 'good' old xsd file (in the app_code folder of a website) for the DAL, JustCode pretty much fails to detect anything defined in there. I'm not even sure if you can still create xsd in VS2008 but its a legacy project.