This project is read-only.

SA1649 fires for correctly named file with

Mar 23, 2011 at 8:25 AM
Edited Mar 23, 2011 at 8:37 AM

I have a class ParamBool which is in file ParamBool.cs and with stylecop it fires:

Warning    1    SA1649:

The file attribute in the file header's copyright tag must contain the name of the first type in the file.    C:\******\ParamBool.cs   

The header is:

// <copyright file="ParamBool.cs" company="*****">
// Copyright (c) 2010 All Rights Reserved
// </copyright>

The class header is:

    public sealed class ParamBool

Why is SA1649 firing? If I change the header to be file="ParamBool", then SA1638 fires as well!

Also I cannot find SA1649 in the options to turn it off.

This problem affects sealed classes rather than unsealed classes.

It affects classes like ParamBoolList in file ParamBoolList.aspx.cs

Mar 23, 2011 at 8:59 AM
Edited Mar 23, 2011 at 9:28 AM

Is the ParamBool class in a namespace at all? Please attach a repro file to the bug.

Mar 23, 2011 at 9:27 AM
This discussion has been copied to a work item. Click here to go to the work item and continue the discussion.