[Mono-list] is inaccessible due to its protection level (CS0122).possible Bug?

Andy Hume andyhume32 at yahoo.co.uk
Thu May 10 06:50:14 EDT 2007


Could you provide a single .cs file that reproduces this.

I copied your code into one .cs file, put a class definition
("Download") around the first method, then compiling with both MSFT and
Mono compilers produces a CS0051 "Inconsistent accessibility" error.
Note that the class "Search" has default accessibility "internal", not
public.  Adding "public" before the partial fixes the error.  I don't
see a CS0122.

Andy


> -----Original Message-----
> From: mono-list-bounces at lists.ximian.com 
> [mailto:mono-list-bounces at lists.ximian.com] On Behalf Of DW
> Sent: 10 May 2007 11:03
> To: Mono-list at lists.ximian.com
> Subject: [Mono-list] is inaccessible due to its protection 
> level (CS0122).possible Bug?
> 
> Hello,
> i get the compile error if i try to run my app from 
> Sharpdevelop on my Windows Box. MS compiler isn't complaining.
> on my Linux Testing box a different mono Version is running 
> the app without problems.
> 
> Here are my version.
> 
> //Windows
> Mono JIT compiler version 1.2.3.1, (C) 2002-2006 Novell, Inc 
> and Contributors. www.mono-project.com
>         TLS:           normal
>         GC:            Included Boehm (with typed GC)
>         SIGSEGV:       normal
>         Architecture:  x86
>         Disabled:      none
>         
> //Linux
> Mono JIT compiler version 1.2.2.1, (C) 2002-2006 Novell, Inc 
> and Contributors. www.mono-project.com
>         TLS:           normal
>         GC:            Included Boehm (with typed GC)
>         SIGSEGV:       normal
>         Disabled:      none        
> 
> 
> the compiler is complaining about Result of Search.Result
> 
> public Download(Search.Result result)
> {
>   //CODE
>   ...
> }
> 
> here's the class:
> 
> partial class Search
> {
>   public sealed partial class Result
>   {
>     //CODE
>     ...
>   }
> }
> 
> _______________________________________________
> Mono-list maillist  -  Mono-list at lists.ximian.com 
> http://lists.ximian.com/mailman/listinfo/mono-list



More information about the Mono-list mailing list