T
Tony Johansson
Hi!
Here I have a simple program that is not CLSCompliant because of two things
1. Two methods with same name but differ in case.
2. The program return an uint which should not be CLSCompliant
As you can see I have declared the CLSCompliantAttribute as an assembly
attribut but the compilers is happy
and give not a single warning about this.
Can somebody explain this ?
using System;
using System.Collections.Generic;
using System.Text;
[assembly: CLSCompliantAttribute(true)]
namespace ConsoleApplication8
{
class Program
{
uint tal = 2;
public uint Foo()
{
return tal;
}
public uint FOO()
{
return tal;
}
static void Main(string[] args)
{
Program prog = new Program();
}
}
}
//Tony
Here I have a simple program that is not CLSCompliant because of two things
1. Two methods with same name but differ in case.
2. The program return an uint which should not be CLSCompliant
As you can see I have declared the CLSCompliantAttribute as an assembly
attribut but the compilers is happy
and give not a single warning about this.
Can somebody explain this ?
using System;
using System.Collections.Generic;
using System.Text;
[assembly: CLSCompliantAttribute(true)]
namespace ConsoleApplication8
{
class Program
{
uint tal = 2;
public uint Foo()
{
return tal;
}
public uint FOO()
{
return tal;
}
static void Main(string[] args)
{
Program prog = new Program();
}
}
}
//Tony