bugDotGNU Portable.NET - Bugs: bug #1968, cscc allows access modifier...

 
 

You are not allowed to post comments on this tracker with your current authentication level.

bug #1968: cscc allows access modifier changes to virual/override methods

Submitted by:  None
Submitted on:  Thu 12 Dec 2002 06:35:25 PM UTC  
 
Category: NoneSeverity: 3 - Normal
Item Group: NoneStatus: Fixed
Privacy: PublicAssigned to: None
Open/Closed: Closed

Thu 12 Dec 2002 07:33:59 PM UTC, comment #1:

Fixed in CVS now.

<new error>
cscc virtual.cs
virtual.cs:17: cannot change the access modifiers while overriding virtual method 'Widget::VirtualMethod' with 'SubWidget::VirtualMethod'
</error>

Gopal.V <t3rmin4t0r>
Project Administrator
Thu 12 Dec 2002 06:35:25 PM UTC, original submission:

using System;

public class Widget
{
public Widget (): base() {}

public virtual string VirtualMethod ()
{
return "Widget::VirtualMethod";
}
}

public class SubWidget: Widget
{
public SubWidget (): base () {}

protected override string VirtualMethod ()
{
return "SubWidget::VirtualMethod";
}
}

public class Testing
{
public static void Main()
{
}
}

cscc allows this while other compilers do not

Anonymous

 

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

CC list is empty

 

Do you think this task is very important?
If so, you can click here to add your encouragement to it.
This task has 0 encouragements so far.

Only logged-in users can vote.

 

Please enter the title of George Orwell's famous dystopian book (it's a date):

 

 

Follow 2 latest changes.

Date Changed By Updated Field Previous Value => Replaced By
Thu 12 Dec 2002 07:33:59 PM UTCt3rmin4t0rStatusNone=>(Error - Not Found)
  Open/ClosedOpen=>(Error - Not Found)

Back to the top


Powered by Savane 3.1-cleanup1