Semantics\PrimaryConstructorTests.cs (446)
7272("0004", BadReference | NotUsedWarning | Shadows, "public static int F = p1;"),
7273("0005", BadReference | NotUsedWarning | Shadows | BadConstant, "public const int F = p1;"),
7274("0006", BadReference | NotUsedWarning | Shadows, "public static int P {get;} = p1;"),
7275("0007", BadReference | NotUsedWarning | Shadows, "public static event System.Action E = () => p1.ToString();"),
7276("0008", BadReference | NotUsedWarning, "static C1() { p1 = 0; }"),
7277("0009", BadReference | NotUsedWarning, "static void M() { p1 = 0; }"),
7278("0011", BadReference | NotUsedWarning, "static int P { get { return p1; } }"),
7279("0012", BadReference | NotUsedWarning, "static int P { set { p1 = 0; } }"),
7280("0013", BadReference | NotUsedWarning, "static int P { set {} get { return p1; } }"),
7281("0014", BadReference | NotUsedWarning, "static int P { get => 0; set { p1 = 0; } }"),
7282("0015", BadReference | NotUsedWarning, "static event System.Action E { add { p1 = 0; } remove {} }"),
7283("0016", BadReference | NotUsedWarning, "static event System.Action E { add {} remove { p1 = 0; } }"),
7299("0101", BadReference | NotUsedWarning, "class Nested { public int F = p1; }"),
7300("0102", BadReference | NotUsedWarning, "class Nested { public int P {get;} = p1; }"),
7301("0103", BadReference | NotUsedWarning, "class Nested { public event System.Action E = () => p1.ToString(); }"),
7302("0104", BadReference | NotUsedWarning, "class Nested { public static int F = p1; }"),
7303("0106", BadReference | NotUsedWarning, "class Nested { public static int P {get;} = p1; }"),
7304("0107", BadReference | NotUsedWarning, "class Nested { public static event System.Action E = () => p1.ToString(); }"),
7305("0108", BadReference | NotUsedWarning, "class Nested { static Nested() { p1 = 0; } }"),
7306("0109", BadReference | NotUsedWarning, "class Nested { static void M() { p1 = 0; } }"),
7307("0111", BadReference | NotUsedWarning, "class Nested { static int P { get { return p1; } } }"),
7308("0112", BadReference | NotUsedWarning, "class Nested { static int P { set { p1 = 0; } } }"),
7309("0113", BadReference | NotUsedWarning, "class Nested { static int P { set {} get { return p1; } } }"),
7310("0114", BadReference | NotUsedWarning, "class Nested { static int P { get => 0; set { p1 = 0; } } }"),
7311("0115", BadReference | NotUsedWarning, "class Nested { static event System.Action E { add { p1 = 0; } remove {} } }"),
7312("0116", BadReference | NotUsedWarning, "class Nested { static event System.Action E { add {} remove { p1 = 0; } } }"),
7313("0117", BadReference | NotUsedWarning, "class Nested { void M() { p1 = 0; } }"),
7314("0118", BadReference | NotUsedWarning, "class Nested { int P { get { return p1; } } }"),
7315("0119", BadReference | NotUsedWarning, "class Nested { int P { set { p1 = 0; } } }"),
7316("0120", BadReference | NotUsedWarning, "class Nested { int P { set {} get { return p1; } } }"),
7317("0121", BadReference | NotUsedWarning, "class Nested { int P { get => 0; set { p1 = 0; } } }"),
7318("0122", BadReference | NotUsedWarning, "class Nested { event System.Action E { add { p1 = 0; } remove {} } }"),
7319("0123", BadReference | NotUsedWarning, "class Nested { event System.Action E { add {} remove { p1 = 0; } } }"),
7320("0124", BadReference | NotUsedWarning, "class Nested { int this[int x] { get { return p1; } } }"),
7321("0125", BadReference | NotUsedWarning, "class Nested { int this[int x] { set { p1 = 0; } } }"),
7322("0126", BadReference | NotUsedWarning, "class Nested { int this[int x] { set {} get { return p1; } } }"),
7323("0127", BadReference | NotUsedWarning, "class Nested { int this[int x] { get => 0; set { p1 = 0; } } }"),
7324("0128", BadReference | NotUsedWarning, "class Nested { ~Nested() { p1 = 0; } }"),
7325("0129", BadReference | NotUsedWarning, "class Nested { public Nested() : this(p1) {} Nested(int x) {} }"),
7326("0130", BadReference | NotUsedWarning, "class Nested { public Nested() { p1 = 0; } }"),
7329("0301", BadReference | NotUsedWarning | BadAttributeValue, "[Attr1(p1)] public int F = 0;"),
7330("0302", BadReference | NotUsedWarning | BadAttributeValue, "[Attr1(p1)] public int P {get;} = 0;"),
7331("0303", BadReference | NotUsedWarning | BadAttributeValue, "[Attr1(p1)] public event System.Action E = () => 0.ToString();"),
7332("0304", BadReference | NotUsedWarning | BadAttributeValue, "[Attr1(p1)] public static int F = 0;"),
7333("0305", BadReference | NotUsedWarning | BadAttributeValue, "[Attr1(p1)] public const int F = 0;"),
7334("0306", BadReference | NotUsedWarning | BadAttributeValue, "[Attr1(p1)] public static int P {get;} = 0;"),
7335("0307", BadReference | NotUsedWarning | BadAttributeValue, "[Attr1(p1)] public static event System.Action E = () => 0.ToString();"),
7336("0308", BadReference | NotUsedWarning | BadAttributeValue, "[Attr1(p1)] static C1() {}"),
7337("0309", BadReference | NotUsedWarning | BadAttributeValue, "[Attr1(p1)] static void M() {}"),
7338("0311", BadReference | NotUsedWarning | BadAttributeValue, "[Attr1(p1)] static int P { get { return 0; } }"),
7339("0312", BadReference | NotUsedWarning | BadAttributeValue, "[Attr1(p1)] static int P { set {} }"),
7340("0313", BadReference | NotUsedWarning | BadAttributeValue, "[Attr1(p1)] static int P { set {} get { return 0; } }"),
7341("0314", BadReference | NotUsedWarning | BadAttributeValue, "[Attr1(p1)] static int P { get => 0; set {} }"),
7342("0315", BadReference | NotUsedWarning | BadAttributeValue, "[Attr1(p1)] static event System.Action E { add {} remove {} }"),
7343("0316", BadReference | NotUsedWarning | BadAttributeValue, "[Attr1(p1)] static event System.Action E { add {} remove {} }"),
7344("0317", BadReference | NotUsedWarning | BadAttributeValue, "[Attr1(p1)] void M() {}"),
7345("0318", BadReference | NotUsedWarning | BadAttributeValue, "[Attr1(p1)] int P { get { return 0; } }"),
7346("0319", BadReference | NotUsedWarning | BadAttributeValue, "[Attr1(p1)] int P { set {} }"),
7347("0320", BadReference | NotUsedWarning | BadAttributeValue, "[Attr1(p1)] int P { set {} get { return 0; } }"),
7348("0321", BadReference | NotUsedWarning | BadAttributeValue, "[Attr1(p1)] int P { get => 0; set {} }"),
7349("0322", BadReference | NotUsedWarning | BadAttributeValue, "[Attr1(p1)] event System.Action E { add {} remove {} }"),
7350("0323", BadReference | NotUsedWarning | BadAttributeValue, "[Attr1(p1)] event System.Action E { add {} remove {} }"),
7351("0324", BadReference | NotUsedWarning | BadAttributeValue, "[Attr1(p1)] int this[int x] { get { return 0; } }"),
7352("0325", BadReference | NotUsedWarning | BadAttributeValue, "[Attr1(p1)] int this[int x] { set {} }"),
7353("0326", BadReference | NotUsedWarning | BadAttributeValue, "[Attr1(p1)] int this[int x] { set {} get { return 0; } }"),
7354("0327", BadReference | NotUsedWarning | BadAttributeValue, "[Attr1(p1)] int this[int x] { get => 0; set {} }"),
7355("0328", BadReference | NotUsedWarning | BadAttributeValue, "[Attr1(p1)] ~C1() {}"),
7356("0329", BadReference | NotUsedWarning | BadAttributeValue, "[Attr1(p1)] public C1() : this(0) {}"),
7357("0330", BadReference | NotUsedWarning | BadAttributeValue, "static int P { [Attr1(p1)] get { return 0; } }"),
7358("0331", BadReference | NotUsedWarning | BadAttributeValue, "static int P { [Attr1(p1)] set {} }"),
7359("0332", BadReference | NotUsedWarning | BadAttributeValue, "static event System.Action E { [Attr1(p1)] add {} remove {} }"),
7360("0333", BadReference | NotUsedWarning | BadAttributeValue, "static event System.Action E { add {} [Attr1(p1)] remove {} }"),
7361("0334", BadReference | NotUsedWarning | BadAttributeValue, "[Attr1(p1)] class Nested {}"),
7362("0335", BadReference | NotUsedWarning | BadAttributeValue, "class Nested([Attr1(p1)] int p2) { public int F = p2; }"),
7365("0401", BadReference | NotUsedWarning | BadAttributeValue, "class Nested { [Attr1(p1)] public int F = 0; }"),
7366("0402", BadReference | NotUsedWarning | BadAttributeValue, "class Nested { [Attr1(p1)] public int P {get;} = 0; }"),
7367("0403", BadReference | NotUsedWarning | BadAttributeValue, "class Nested { [Attr1(p1)] public event System.Action E = () => 0.ToString(); }"),
7368("0404", BadReference | NotUsedWarning | BadAttributeValue, "class Nested { [Attr1(p1)] public static int F = 0; }"),
7369("0406", BadReference | NotUsedWarning | BadAttributeValue, "class Nested { [Attr1(p1)] public static int P {get;} = 0; }"),
7370("0407", BadReference | NotUsedWarning | BadAttributeValue, "class Nested { [Attr1(p1)] public static event System.Action E = () => 0.ToString(); }"),
7371("0408", BadReference | NotUsedWarning | BadAttributeValue, "class Nested { [Attr1(p1)] static Nested() {} }"),
7372("0409", BadReference | NotUsedWarning | BadAttributeValue, "class Nested { [Attr1(p1)] static void M() {} }"),
7373("0411", BadReference | NotUsedWarning | BadAttributeValue, "class Nested { [Attr1(p1)] static int P { get { return 0; } } }"),
7374("0412", BadReference | NotUsedWarning | BadAttributeValue, "class Nested { [Attr1(p1)] static int P { set {} } }"),
7375("0413", BadReference | NotUsedWarning | BadAttributeValue, "class Nested { [Attr1(p1)] static int P { set {} get { return 0; } } }"),
7376("0414", BadReference | NotUsedWarning | BadAttributeValue, "class Nested { [Attr1(p1)] static int P { get => 0; set {} } }"),
7377("0415", BadReference | NotUsedWarning | BadAttributeValue, "class Nested { [Attr1(p1)] static event System.Action E { add {} remove {} } }"),
7378("0416", BadReference | NotUsedWarning | BadAttributeValue, "class Nested { [Attr1(p1)] static event System.Action E { add {} remove {} } }"),
7379("0417", BadReference | NotUsedWarning | BadAttributeValue, "class Nested { [Attr1(p1)] void M() {} }"),
7380("0418", BadReference | NotUsedWarning | BadAttributeValue, "class Nested { [Attr1(p1)] int P { get { return 0; } } }"),
7381("0419", BadReference | NotUsedWarning | BadAttributeValue, "class Nested { [Attr1(p1)] int P { set {} } }"),
7382("0420", BadReference | NotUsedWarning | BadAttributeValue, "class Nested { [Attr1(p1)] int P { set {} get { return 0; } } }"),
7383("0421", BadReference | NotUsedWarning | BadAttributeValue, "class Nested { [Attr1(p1)] int P { get => 0; set {} } }"),
7384("0422", BadReference | NotUsedWarning | BadAttributeValue, "class Nested { [Attr1(p1)] event System.Action E { add {} remove {} } }"),
7385("0423", BadReference | NotUsedWarning | BadAttributeValue, "class Nested { [Attr1(p1)] event System.Action E { add {} remove {} } }"),
7386("0424", BadReference | NotUsedWarning | BadAttributeValue, "class Nested { [Attr1(p1)] int this[int x] { get { return 0; } } }"),
7387("0425", BadReference | NotUsedWarning | BadAttributeValue, "class Nested { [Attr1(p1)] int this[int x] { set {} } }"),
7388("0426", BadReference | NotUsedWarning | BadAttributeValue, "class Nested { [Attr1(p1)] int this[int x] { set {} get { return 0; } } }"),
7389("0427", BadReference | NotUsedWarning | BadAttributeValue, "class Nested { [Attr1(p1)] int this[int x] { get => 0; set {} } }"),
7390("0428", BadReference | NotUsedWarning | BadAttributeValue, "class Nested { [Attr1(p1)] ~Nested() {} }"),
7391("0430", BadReference | NotUsedWarning | BadAttributeValue, "class Nested { [Attr1(p1)] public Nested() {} }"),
7392("0431", BadReference | NotUsedWarning | BadAttributeValue, "class Nested { static int P { [Attr1(p1)] get { return 0; } } }"),
7393("0432", BadReference | NotUsedWarning | BadAttributeValue, "class Nested { static int P { [Attr1(p1)] set {} } }"),
7394("0433", BadReference | NotUsedWarning | BadAttributeValue, "class Nested { static event System.Action E { [Attr1(p1)] add {} remove {} } }"),
7395("0434", BadReference | NotUsedWarning | BadAttributeValue, "class Nested { static event System.Action E { add {} [Attr1(p1)] remove {} } }"),
7396("0435", BadReference | NotUsedWarning | BadAttributeValue, "class Nested { [Attr1(p1)] class Nested2 {} }"),
7397("0436", BadReference | NotUsedWarning | BadAttributeValue, "class Nested { class Nested2([Attr1(p1)] int p2) { public int F = p2; } }"),
7400("0501", NotUsedWarning, "[Attr1(nameof(p1))] public int F = 0;"),
7401("0502", NotUsedWarning, "[Attr1(nameof(p1))] public int P {get;} = 0;"),
7402("0503", NotUsedWarning, "[Attr1(nameof(p1))] public event System.Action E = () => 0.ToString();"),
7403("0504", NotUsedWarning, "[Attr1(nameof(p1))] public static int F = 0;"),
7404("0505", NotUsedWarning, "[Attr1(nameof(p1))] public const int F = 0;"),
7405("0506", NotUsedWarning, "[Attr1(nameof(p1))] public static int P {get;} = 0;"),
7406("0507", NotUsedWarning, "[Attr1(nameof(p1))] public static event System.Action E = () => 0.ToString();"),
7407("0508", NotUsedWarning, "[Attr1(nameof(p1))] static C1() {}"),
7408("0509", NotUsedWarning, "[Attr1(nameof(p1))] static void M() {}"),
7409("0511", NotUsedWarning, "[Attr1(nameof(p1))] static int P { get { return 0; } }"),
7410("0512", NotUsedWarning, "[Attr1(nameof(p1))] static int P { set {} }"),
7411("0513", NotUsedWarning, "[Attr1(nameof(p1))] static int P { set {} get { return 0; } }"),
7412("0514", NotUsedWarning, "[Attr1(nameof(p1))] static int P { get => 0; set {} }"),
7413("0515", NotUsedWarning, "[Attr1(nameof(p1))] static event System.Action E { add {} remove {} }"),
7414("0516", NotUsedWarning, "[Attr1(nameof(p1))] static event System.Action E { add {} remove {} }"),
7415("0517", NotUsedWarning, "[Attr1(nameof(p1))] void M() {}"),
7416("0518", NotUsedWarning, "[Attr1(nameof(p1))] int P { get { return 0; } }"),
7417("0519", NotUsedWarning, "[Attr1(nameof(p1))] int P { set {} }"),
7418("0520", NotUsedWarning, "[Attr1(nameof(p1))] int P { set {} get { return 0; } }"),
7419("0521", NotUsedWarning, "[Attr1(nameof(p1))] int P { get => 0; set {} }"),
7420("0522", NotUsedWarning, "[Attr1(nameof(p1))] event System.Action E { add {} remove {} }"),
7421("0523", NotUsedWarning, "[Attr1(nameof(p1))] event System.Action E { add {} remove {} }"),
7422("0524", NotUsedWarning, "[Attr1(nameof(p1))] int this[int x] { get { return 0; } }"),
7423("0525", NotUsedWarning, "[Attr1(nameof(p1))] int this[int x] { set {} }"),
7424("0526", NotUsedWarning, "[Attr1(nameof(p1))] int this[int x] { set {} get { return 0; } }"),
7425("0527", NotUsedWarning, "[Attr1(nameof(p1))] int this[int x] { get => 0; set {} }"),
7426("0528", NotUsedWarning, "[Attr1(nameof(p1))] ~C1() {}"),
7427("0529", NotUsedWarning, "[Attr1(nameof(p1))] public C1() : this(0) {}"),
7428("0530", NotUsedWarning, "static int P { [Attr1(nameof(p1))] get { return 0; } }"),
7429("0531", NotUsedWarning, "static int P { [Attr1(nameof(p1))] set {} }"),
7430("0532", NotUsedWarning, "static event System.Action E { [Attr1(nameof(p1))] add {} remove {} }"),
7431("0533", NotUsedWarning, "static event System.Action E { add {} [Attr1(nameof(p1))] remove {} }"),
7432("0534", NotUsedWarning, "[Attr1(nameof(p1))] class Nested {}"),
7433("0535", NotUsedWarning, "class Nested([Attr1(nameof(p1))] int p2) { public int F = p2; }"),
7436("0601", NotUsedWarning, "class Nested { [Attr1(nameof(p1))] public int F = 0; }"),
7437("0602", NotUsedWarning, "class Nested { [Attr1(nameof(p1))] public int P {get;} = 0; }"),
7438("0603", NotUsedWarning, "class Nested { [Attr1(nameof(p1))] public event System.Action E = () => 0.ToString(); }"),
7439("0604", NotUsedWarning, "class Nested { [Attr1(nameof(p1))] public static int F = 0; }"),
7440("0606", NotUsedWarning, "class Nested { [Attr1(nameof(p1))] public static int P {get;} = 0; }"),
7441("0607", NotUsedWarning, "class Nested { [Attr1(nameof(p1))] public static event System.Action E = () => 0.ToString(); }"),
7442("0608", NotUsedWarning, "class Nested { [Attr1(nameof(p1))] static Nested() {} }"),
7443("0609", NotUsedWarning, "class Nested { [Attr1(nameof(p1))] static void M() {} }"),
7444("0611", NotUsedWarning, "class Nested { [Attr1(nameof(p1))] static int P { get { return 0; } } }"),
7445("0612", NotUsedWarning, "class Nested { [Attr1(nameof(p1))] static int P { set {} } }"),
7446("0613", NotUsedWarning, "class Nested { [Attr1(nameof(p1))] static int P { set {} get { return 0; } } }"),
7447("0614", NotUsedWarning, "class Nested { [Attr1(nameof(p1))] static int P { get => 0; set {} } }"),
7448("0615", NotUsedWarning, "class Nested { [Attr1(nameof(p1))] static event System.Action E { add {} remove {} } }"),
7449("0616", NotUsedWarning, "class Nested { [Attr1(nameof(p1))] static event System.Action E { add {} remove {} } }"),
7450("0617", NotUsedWarning, "class Nested { [Attr1(nameof(p1))] void M() {} }"),
7451("0618", NotUsedWarning, "class Nested { [Attr1(nameof(p1))] int P { get { return 0; } } }"),
7452("0619", NotUsedWarning, "class Nested { [Attr1(nameof(p1))] int P { set {} } }"),
7453("0620", NotUsedWarning, "class Nested { [Attr1(nameof(p1))] int P { set {} get { return 0; } } }"),
7454("0621", NotUsedWarning, "class Nested { [Attr1(nameof(p1))] int P { get => 0; set {} } }"),
7455("0622", NotUsedWarning, "class Nested { [Attr1(nameof(p1))] event System.Action E { add {} remove {} } }"),
7456("0623", NotUsedWarning, "class Nested { [Attr1(nameof(p1))] event System.Action E { add {} remove {} } }"),
7457("0624", NotUsedWarning, "class Nested { [Attr1(nameof(p1))] int this[int x] { get { return 0; } } }"),
7458("0625", NotUsedWarning, "class Nested { [Attr1(nameof(p1))] int this[int x] { set {} } }"),
7459("0626", NotUsedWarning, "class Nested { [Attr1(nameof(p1))] int this[int x] { set {} get { return 0; } } }"),
7460("0627", NotUsedWarning, "class Nested { [Attr1(nameof(p1))] int this[int x] { get => 0; set {} } }"),
7461("0628", NotUsedWarning, "class Nested { [Attr1(nameof(p1))] ~Nested() {} }"),
7462("0630", NotUsedWarning, "class Nested { [Attr1(nameof(p1))] public Nested() {} }"),
7463("0631", NotUsedWarning, "class Nested { static int P { [Attr1(nameof(p1))] get { return 0; } } }"),
7464("0632", NotUsedWarning, "class Nested { static int P { [Attr1(nameof(p1))] set {} } }"),
7465("0633", NotUsedWarning, "class Nested { static event System.Action E { [Attr1(nameof(p1))] add {} remove {} } }"),
7466("0634", NotUsedWarning, "class Nested { static event System.Action E { add {} [Attr1(nameof(p1))] remove {} } }"),
7467("0635", NotUsedWarning, "class Nested { [Attr1(nameof(p1))] class Nested2 {} }"),
7468("0636", NotUsedWarning, "class Nested { class Nested2([Attr1(nameof(p1))] int p2) { public int F = p2; } }"),
7471("0709", BadReference | NotUsedWarning | BadDefaultValue, "static void M(int x = p1) {}"),
7472("0717", BadReference | NotUsedWarning | BadDefaultValue, "void M(int x = p1) {}"),
7473("0724", BadReference | NotUsedWarning | BadDefaultValue, "int this[int y, int x = p1] { get { return x; } }"),
7474("0730", BadReference | NotUsedWarning | BadDefaultValue, "public C1(int y, int x = p1) : this(0) {}"),
7475("0731", BadReference | NotUsedWarning | BadDefaultValue, "class Nested(int y, int x = p1) { public int F = x + y; }"),
7478("0809", BadReference | NotUsedWarning | BadDefaultValue, "class Nested { static void M(int x = p1) {} }"),
7479("0817", BadReference | NotUsedWarning | BadDefaultValue, "class Nested { void M(int x = p1) {} }"),
7480("0824", BadReference | NotUsedWarning | BadDefaultValue, "class Nested { int this[int y, int x = p1] { get { return x; } } }"),
7481("0830", BadReference | NotUsedWarning | BadDefaultValue, "class Nested { public Nested(int x = p1) {} }"),
7482("0831", BadReference | NotUsedWarning | BadDefaultValue, "class Nested { class Nested2(int y, int x = p1) { public int F = x + y; } }"),
7485("0909", NotUsedWarning, "static void M(string x = nameof(p1)) {}"),
7486("0917", NotUsedWarning, "void M(string x = nameof(p1)) {}"),
7487("0924", NotUsedWarning, "int this[int y, string x = nameof(p1)] { get { return y; } }"),
7488("0930", NotUsedWarning, "public C1(int y, string x = nameof(p1)) : this(0) {}"),
7489("0931", NotUsedWarning, "class Nested(int y, string x = nameof(p1)) { public int F = x.Length + y; }"),
7492("1009", NotUsedWarning, "class Nested { static void M(string x = nameof(p1)) {} }"),
7493("1017", NotUsedWarning, "class Nested { void M(string x = nameof(p1)) {} }"),
7494("1024", NotUsedWarning, "class Nested { int this[int y, string x = nameof(p1)] { get { return y; } } }"),
7495("1030", NotUsedWarning, "class Nested { public Nested(string x = nameof(p1)) {} }"),
7496("1031", NotUsedWarning, "class Nested { class Nested2(int y, string x = nameof(p1)) { public int F = x.Length + y; } }"),
7520("1506", BadReference | NotUsedWarning, "public static int P => p1;"),
7521("1508", BadReference | NotUsedWarning, "static C1() => p1 = 0;"),
7522("1509", BadReference | NotUsedWarning, "static void M() => p1 = 0;"),
7523("1511", BadReference | NotUsedWarning, "static int P { get => p1; }"),
7524("1512", BadReference | NotUsedWarning, "static int P { set => p1 = 0; }"),
7525("1513", BadReference | NotUsedWarning, "static int P { set {} get => p1; }"),
7526("1514", BadReference | NotUsedWarning, "static int P { get => 0; set => p1 = 0; }"),
7527("1515", BadReference | NotUsedWarning, "static event System.Action E { add => p1 = 0; remove {} }"),
7528("1516", BadReference | NotUsedWarning, "static event System.Action E { add {} remove => p1 = 0; }"),
7540("1602", BadReference | NotUsedWarning, "class Nested { public int P => p1; }"),
7541("1606", BadReference | NotUsedWarning, "class Nested { public static int P => p1; }"),
7542("1608", BadReference | NotUsedWarning, "class Nested { static Nested() => p1 = 0; }"),
7543("1609", BadReference | NotUsedWarning, "class Nested { static void M() => p1 = 0; }"),
7544("1611", BadReference | NotUsedWarning, "class Nested { static int P { get => p1; } }"),
7545("1612", BadReference | NotUsedWarning, "class Nested { static int P { set => p1 = 0; } }"),
7546("1613", BadReference | NotUsedWarning, "class Nested { static int P { set {} get => p1; } }"),
7547("1614", BadReference | NotUsedWarning, "class Nested { static int P { get => 0; set => p1 = 0; } }"),
7548("1617", BadReference | NotUsedWarning, "class Nested { void M() => p1 = 0; }"),
7549("1618", BadReference | NotUsedWarning, "class Nested { int P { get => p1; } }"),
7550("1619", BadReference | NotUsedWarning, "class Nested { int P { set => p1 = 0; } }"),
7551("1620", BadReference | NotUsedWarning, "class Nested { int P { set {} get => p1; } }"),
7552("1621", BadReference | NotUsedWarning, "class Nested { int P { get => 0; set => p1 = 0; } }"),
7553("1624", BadReference | NotUsedWarning, "class Nested { int this[int x] { get => p1; } }"),
7554("1625", BadReference | NotUsedWarning, "class Nested { int this[int x] { set => p1 = 0; } }"),
7555("1626", BadReference | NotUsedWarning, "class Nested { int this[int x] { set {} get => p1; } }"),
7556("1627", BadReference | NotUsedWarning, "class Nested { int this[int x] { get => 0; set => p1 = 0; } }"),
7557("1628", BadReference | NotUsedWarning, "class Nested { ~Nested() => p1 = 0; }"),
7558("1629", BadReference | NotUsedWarning, "class Nested { public Nested() : this(p1) {} Nested(int x) {} }"),
7559("1630", BadReference | NotUsedWarning, "class Nested { public Nested() => p1 = 0; }"),
7562("1708", NotUsedWarning | TwoBodies, "static C1() {} => p1 = 0;"),
7563("1709", NotUsedWarning | TwoBodies, "static void M() {} => p1 = 0;"),
7564("1711", NotUsedWarning | TwoBodies, "static int P { get { return 0; } => p1; }"),
7565("1712", NotUsedWarning | TwoBodies, "static int P { set {} => p1 = 0; }"),
7566("1713", NotUsedWarning | TwoBodies, "static int P { set {} get { return 0; } => p1; }"),
7567("1714", NotUsedWarning | TwoBodies, "static int P { get => 0; set {} => p1 = 0; }"),
7568("1715", NotUsedWarning | TwoBodies, "static event System.Action E { add {} => p1 = 0; remove {} }"),
7569("1716", NotUsedWarning | TwoBodies, "static event System.Action E { add {} remove {} => p1 = 0; }"),
7582("1808", NotUsedWarning | TwoBodies, "class Nested { static Nested() {} => p1 = 0; }"),
7583("1809", NotUsedWarning | TwoBodies, "class Nested { static void M() {} => p1 = 0; }"),
7584("1811", NotUsedWarning | TwoBodies, "class Nested { static int P { get { return 0; } => p1; } }"),
7585("1812", NotUsedWarning | TwoBodies, "class Nested { static int P { set {} => p1 = 0; } }"),
7586("1813", NotUsedWarning | TwoBodies, "class Nested { static int P { set {} get { return 0; } => p1; } }"),
7587("1814", NotUsedWarning | TwoBodies, "class Nested { static int P { get => 0; set {} => p1 = 0; } }"),
7588("1817", NotUsedWarning | TwoBodies, "class Nested { void M() {} => p1 = 0; }"),
7589("1818", NotUsedWarning | TwoBodies, "class Nested { int P { get { return 0; } => p1; } }"),
7590("1819", NotUsedWarning | TwoBodies, "class Nested { int P { set {} => p1 = 0; } }"),
7591("1820", NotUsedWarning | TwoBodies, "class Nested { int P { set {} get { return 0; } => p1; } }"),
7592("1821", NotUsedWarning | TwoBodies, "class Nested { int P { get => 0; set {} => p1 = 0; } }"),
7593("1824", NotUsedWarning | TwoBodies, "class Nested { int this[int x] { get { return 0; } => p1; } }"),
7594("1825", NotUsedWarning | TwoBodies, "class Nested { int this[int x] { set {} => p1 = 0; } }"),
7595("1826", NotUsedWarning | TwoBodies, "class Nested { int this[int x] { set {} get { return 0; } => p1; } }"),
7596("1827", NotUsedWarning | TwoBodies, "class Nested { int this[int x] { get => 0; set {} => p1 = 0; } }"),
7597("1828", NotUsedWarning | TwoBodies, "class Nested { ~Nested() {} => p1 = 0; }"),
7598("1830", NotUsedWarning | TwoBodies, "class Nested { public Nested() {} => p1 = 0; }"),
7601("1901", NotUsedWarning | AttributesNotAllowed | Shadows, "public System.Action F = () => { [Attr1(p1)] return; };"),
7602("1902", NotUsedWarning | AttributesNotAllowed | Shadows, "public System.Action P {get;} = () => { [Attr1(p1)] return; };"),
7603("1903", NotUsedWarning | AttributesNotAllowed | Shadows, "public event System.Action E = () => { [Attr1(p1)] return; };"),
7604("1904", NotUsedWarning | AttributesNotAllowed | Shadows, "public static System.Action F = () => { [Attr1(p1)] return; };"),
7605("1906", NotUsedWarning | AttributesNotAllowed | Shadows, "public static System.Action P {get;} = () => { [Attr1(p1)] return; };"),
7606("1907", NotUsedWarning | AttributesNotAllowed | Shadows, "public static event System.Action E = () => { [Attr1(p1)] return; };"),
7607("1908", NotUsedWarning | AttributesNotAllowed, "static C1() { [Attr1(p1)] return; }"),
7608("1909", NotUsedWarning | AttributesNotAllowed, "static void M() { [Attr1(p1)] return; }"),
7609("1911", NotUsedWarning | AttributesNotAllowed, "static int P { get { [Attr1(p1)] return 0; } }"),
7610("1912", NotUsedWarning | AttributesNotAllowed, "static int P { set { [Attr1(p1)] return; } }"),
7611("1913", NotUsedWarning | AttributesNotAllowed, "static int P { set {} get { [Attr1(p1)] return 0; } }"),
7612("1914", NotUsedWarning | AttributesNotAllowed, "static int P { get => 0; set { [Attr1(p1)] return; } }"),
7613("1915", NotUsedWarning | AttributesNotAllowed, "static event System.Action E { add { [Attr1(p1)] return; } remove {} }"),
7614("1916", NotUsedWarning | AttributesNotAllowed, "static event System.Action E { add {} remove { [Attr1(p1)] return; } }"),
7615("1917", NotUsedWarning | AttributesNotAllowed, "void M() { [Attr1(p1)] return; }"),
7616("1918", NotUsedWarning | AttributesNotAllowed, "int P { get { [Attr1(p1)] return 0; } }"),
7617("1919", NotUsedWarning | AttributesNotAllowed, "int P { set { [Attr1(p1)] return; } }"),
7618("1920", NotUsedWarning | AttributesNotAllowed, "int P { set {} get { [Attr1(p1)] return 0; } }"),
7619("1921", NotUsedWarning | AttributesNotAllowed, "int P { get => 0; set { [Attr1(p1)] return; } }"),
7620("1922", NotUsedWarning | AttributesNotAllowed, "event System.Action E { add { [Attr1(p1)] return; } remove {} }"),
7621("1923", NotUsedWarning | AttributesNotAllowed, "event System.Action E { add {} remove { [Attr1(p1)] return; } }"),
7622("1924", NotUsedWarning | AttributesNotAllowed, "int this[int x] { get { [Attr1(p1)] return 0; } }"),
7623("1925", NotUsedWarning | AttributesNotAllowed, "int this[int x] { set { [Attr1(p1)] return; } }"),
7624("1926", NotUsedWarning | AttributesNotAllowed, "int this[int x] { set {} get { [Attr1(p1)] return 0; } }"),
7625("1927", NotUsedWarning | AttributesNotAllowed, "int this[int x] { get => 0; set { [Attr1(p1)] return; } }"),
7626("1928", NotUsedWarning | AttributesNotAllowed, "~C1() { [Attr1(p1)] return; }"),
7627("1929", NotUsedWarning | AttributesNotAllowed, "public C1() : this(() => { [Attr1(p1)] return; }) {} C1(System.Action x) : this(0) {}"),
7628("1930", NotUsedWarning | AttributesNotAllowed, "public C1() : this(0) { [Attr1(p1)] return; }"),
7629("1935", NotUsedWarning | AttributesNotAllowed, "class Nested() : NestedBase(() => { [Attr1(p1)] return; }) {} class NestedBase(System.Action x) { object F = x; } "),
7631("2001", BadReference | NotUsedWarning | BadAttributeValue | Shadows, "public System.Action F = () => { [Attr1(p1)] void local(){} local(); };"),
7632("2002", BadReference | NotUsedWarning | BadAttributeValue | Shadows, "public System.Action P {get;} = () => { [Attr1(p1)] void local(){} local(); };"),
7633("2003", BadReference | NotUsedWarning | BadAttributeValue | Shadows, "public event System.Action E = () => { [Attr1(p1)] void local(){} local(); };"),
7634("2004", BadReference | NotUsedWarning | BadAttributeValue | Shadows, "public static System.Action F = () => { [Attr1(p1)] void local(){} local(); };"),
7635("2006", BadReference | NotUsedWarning | BadAttributeValue | Shadows, "public static System.Action P {get;} = () => { [Attr1(p1)] void local(){} local(); };"),
7636("2007", BadReference | NotUsedWarning | BadAttributeValue | Shadows, "public static event System.Action E = () => { [Attr1(p1)] void local(){} local(); };"),
7637("2008", BadReference | NotUsedWarning | BadAttributeValue, "static C1() { [Attr1(p1)] void local(){} local(); }"),
7638("2009", BadReference | NotUsedWarning | BadAttributeValue, "static void M() { [Attr1(p1)] void local(){} local(); }"),
7639("2011", BadReference | NotUsedWarning | BadAttributeValue, "static int P { get { [Attr1(p1)] void local(){} local(); return 0; } }"),
7640("2012", BadReference | NotUsedWarning | BadAttributeValue, "static int P { set { [Attr1(p1)] void local(){} local(); } }"),
7641("2013", BadReference | NotUsedWarning | BadAttributeValue, "static int P { set {} get { [Attr1(p1)] void local(){} local(); return 0; } }"),
7642("2014", BadReference | NotUsedWarning | BadAttributeValue, "static int P { get => 0; set { [Attr1(p1)] void local(){} local(); } }"),
7643("2015", BadReference | NotUsedWarning | BadAttributeValue, "static event System.Action E { add { [Attr1(p1)] void local(){} local(); } remove {} }"),
7644("2016", BadReference | NotUsedWarning | BadAttributeValue, "static event System.Action E { add {} remove { [Attr1(p1)] void local(){} local(); } }"),
7645("2017", BadReference | NotUsedWarning | BadAttributeValue, "void M() { [Attr1(p1)] void local(){} local(); }"),
7646("2018", BadReference | NotUsedWarning | BadAttributeValue, "int P { get { [Attr1(p1)] void local(){} local(); return 0; } }"),
7647("2019", BadReference | NotUsedWarning | BadAttributeValue, "int P { set { [Attr1(p1)] void local(){} local(); } }"),
7648("2020", BadReference | NotUsedWarning | BadAttributeValue, "int P { set {} get { [Attr1(p1)] void local(){} local(); return 0; } }"),
7649("2021", BadReference | NotUsedWarning | BadAttributeValue, "int P { get => 0; set { [Attr1(p1)] void local(){} local(); } }"),
7650("2022", BadReference | NotUsedWarning | BadAttributeValue, "event System.Action E { add { [Attr1(p1)] void local(){} local(); } remove {} }"),
7651("2023", BadReference | NotUsedWarning | BadAttributeValue, "event System.Action E { add {} remove { [Attr1(p1)] void local(){} local(); } }"),
7652("2024", BadReference | NotUsedWarning | BadAttributeValue, "int this[int x] { get { [Attr1(p1)] void local(){} local(); return 0; } }"),
7653("2025", BadReference | NotUsedWarning | BadAttributeValue, "int this[int x] { set { [Attr1(p1)] void local(){} local(); } }"),
7654("2026", BadReference | NotUsedWarning | BadAttributeValue, "int this[int x] { set {} get { [Attr1(p1)] void local(){} local(); return 0; } }"),
7655("2027", BadReference | NotUsedWarning | BadAttributeValue, "int this[int x] { get => 0; set { [Attr1(p1)] void local(){} local(); } }"),
7656("2028", BadReference | NotUsedWarning | BadAttributeValue, "~C1() { [Attr1(p1)] void local(){} local(); }"),
7657("2029", BadReference | NotUsedWarning | BadAttributeValue, "public C1() : this(() => { [Attr1(p1)] void local(){} local(); }) {} C1(System.Action x) : this(0) {}"),
7658("2030", BadReference | NotUsedWarning | BadAttributeValue, "public C1() : this(0) { [Attr1(p1)] void local(){} local(); }"),
7659("2035", BadReference | NotUsedWarning | BadAttributeValue, "class Nested() : NestedBase(() => { [Attr1(p1)] void local(){} local(); }) {} class NestedBase(System.Action x) { object F = x; } "),
7665("2104", NotUsedWarning | Shadows, "public static System.Action F = () => { [Attr1(nameof(p1))] void local(){} local(); };"),
7666("2106", NotUsedWarning | Shadows, "public static System.Action P {get;} = () => { [Attr1(nameof(p1))] void local(){} local(); };"),
7667("2107", NotUsedWarning | Shadows, "public static event System.Action E = () => { [Attr1(nameof(p1))] void local(){} local(); };"),
7668("2108", NotUsedWarning, "static C1() { [Attr1(nameof(p1))] void local(){} local(); }"),
7669("2109", NotUsedWarning, "static void M() { [Attr1(nameof(p1))] void local(){} local(); }"),
7670("2111", NotUsedWarning, "static int P { get { [Attr1(nameof(p1))] void local(){} local(); return 0; } }"),
7671("2112", NotUsedWarning, "static int P { set { [Attr1(nameof(p1))] void local(){} local(); } }"),
7672("2113", NotUsedWarning, "static int P { set {} get { [Attr1(nameof(p1))] void local(){} local(); return 0; } }"),
7673("2114", NotUsedWarning, "static int P { get => 0; set { [Attr1(nameof(p1))] void local(){} local(); } }"),
7674("2115", NotUsedWarning, "static event System.Action E { add { [Attr1(nameof(p1))] void local(){} local(); } remove {} }"),
7675("2116", NotUsedWarning, "static event System.Action E { add {} remove { [Attr1(nameof(p1))] void local(){} local(); } }"),
7676("2117", NotUsedWarning, "void M() { [Attr1(nameof(p1))] void local(){} local(); }"),
7677("2118", NotUsedWarning, "int P { get { [Attr1(nameof(p1))] void local(){} local(); return 0; } }"),
7678("2119", NotUsedWarning, "int P { set { [Attr1(nameof(p1))] void local(){} local(); } }"),
7679("2120", NotUsedWarning, "int P { set {} get { [Attr1(nameof(p1))] void local(){} local(); return 0; } }"),
7680("2121", NotUsedWarning, "int P { get => 0; set { [Attr1(nameof(p1))] void local(){} local(); } }"),
7681("2122", NotUsedWarning, "event System.Action E { add { [Attr1(nameof(p1))] void local(){} local(); } remove {} }"),
7682("2123", NotUsedWarning, "event System.Action E { add {} remove { [Attr1(nameof(p1))] void local(){} local(); } }"),
7683("2124", NotUsedWarning, "int this[int x] { get { [Attr1(nameof(p1))] void local(){} local(); return 0; } }"),
7684("2125", NotUsedWarning, "int this[int x] { set { [Attr1(nameof(p1))] void local(){} local(); } }"),
7685("2126", NotUsedWarning, "int this[int x] { set {} get { [Attr1(nameof(p1))] void local(){} local(); return 0; } }"),
7686("2127", NotUsedWarning, "int this[int x] { get => 0; set { [Attr1(nameof(p1))] void local(){} local(); } }"),
7687("2128", NotUsedWarning, "~C1() { [Attr1(nameof(p1))] void local(){} local(); }"),
7688("2129", NotUsedWarning, "public C1() : this(() => { [Attr1(nameof(p1))] void local(){} local(); }) {} C1(System.Action x) : this(0) {}"),
7689("2130", NotUsedWarning, "public C1() : this(0) { [Attr1(nameof(p1))] void local(){} local(); }"),
7690("2135", NotUsedWarning, "class Nested() : NestedBase(() => { [Attr1(nameof(p1))] void local(){} local(); }) {} class NestedBase(System.Action x) { object F = x; } "),
7696("2204", BadReference | NotUsedWarning | BadDefaultValue | Shadows, "public static System.Action F = () => { void local(int x = p1){} local(); };"),
7697("2206", BadReference | NotUsedWarning | BadDefaultValue | Shadows, "public static System.Action P {get;} = () => { void local(int x = p1){} local(); };"),
7698("2207", BadReference | NotUsedWarning | BadDefaultValue | Shadows, "public static event System.Action E = () => { void local(int x = p1){} local(); };"),
7699("2208", BadReference | NotUsedWarning | BadDefaultValue, "static C1() { void local(int x = p1){} local(); }"),
7700("2209", BadReference | NotUsedWarning | BadDefaultValue, "static void M() { void local(int x = p1){} local(); }"),
7701("2211", BadReference | NotUsedWarning | BadDefaultValue, "static int P { get { void local(int x = p1){} local(); return 0; } }"),
7702("2212", BadReference | NotUsedWarning | BadDefaultValue, "static int P { set { void local(int x = p1){} local(); } }"),
7703("2213", BadReference | NotUsedWarning | BadDefaultValue, "static int P { set {} get { void local(int x = p1){} local(); return 0; } }"),
7704("2214", BadReference | NotUsedWarning | BadDefaultValue, "static int P { get => 0; set { void local(int x = p1){} local(); } }"),
7705("2215", BadReference | NotUsedWarning | BadDefaultValue, "static event System.Action E { add { void local(int x = p1){} local(); } remove {} }"),
7706("2216", BadReference | NotUsedWarning | BadDefaultValue, "static event System.Action E { add {} remove { void local(int x = p1){} local(); } }"),
7707("2217", BadReference | NotUsedWarning | BadDefaultValue, "void M() { void local(int x = p1){} local(); }"),
7708("2218", BadReference | NotUsedWarning | BadDefaultValue, "int P { get { void local(int x = p1){} local(); return 0; } }"),
7709("2219", BadReference | NotUsedWarning | BadDefaultValue, "int P { set { void local(int x = p1){} local(); } }"),
7710("2220", BadReference | NotUsedWarning | BadDefaultValue, "int P { set {} get { void local(int x = p1){} local(); return 0; } }"),
7711("2221", BadReference | NotUsedWarning | BadDefaultValue, "int P { get => 0; set { void local(int x = p1){} local(); } }"),
7712("2222", BadReference | NotUsedWarning | BadDefaultValue, "event System.Action E { add { void local(int x = p1){} local(); } remove {} }"),
7713("2223", BadReference | NotUsedWarning | BadDefaultValue, "event System.Action E { add {} remove { void local(int x = p1){} local(); } }"),
7714("2224", BadReference | NotUsedWarning | BadDefaultValue, "int this[int x] { get { void local(int x = p1){} local(); return 0; } }"),
7715("2225", BadReference | NotUsedWarning | BadDefaultValue, "int this[int x] { set { void local(int x = p1){} local(); } }"),
7716("2226", BadReference | NotUsedWarning | BadDefaultValue, "int this[int x] { set {} get { void local(int x = p1){} local(); return 0; } }"),
7717("2227", BadReference | NotUsedWarning | BadDefaultValue, "int this[int x] { get => 0; set { void local(int x = p1){} local(); } }"),
7718("2228", BadReference | NotUsedWarning | BadDefaultValue, "~C1() { void local(int x = p1){} local(); }"),
7719("2229", BadReference | NotUsedWarning | BadDefaultValue, "public C1() : this(() => { void local(int x = p1){} local(); }) {} C1(System.Action x) : this(0) {}"),
7720("2230", BadReference | NotUsedWarning | BadDefaultValue, "public C1() : this(0) { void local(int x = p1){} local(); }"),
7721("2235", BadReference | NotUsedWarning | BadDefaultValue, "class Nested() : NestedBase(() => { void local(int x = p1){} local(); }) {} class NestedBase(System.Action x) { object F = x; } "),
7727("2304", NotUsedWarning | Shadows, "public static System.Action F = () => { void local(string x = nameof(p1)){} local(); };"),
7728("2306", NotUsedWarning | Shadows, "public static System.Action P {get;} = () => { void local(string x = nameof(p1)){} local(); };"),
7729("2307", NotUsedWarning | Shadows, "public static event System.Action E = () => { void local(string x = nameof(p1)){} local(); };"),
7730("2308", NotUsedWarning, "static C1() { void local(string x = nameof(p1)){} local(); }"),
7731("2309", NotUsedWarning, "static void M() { void local(string x = nameof(p1)){} local(); }"),
7732("2311", NotUsedWarning, "static int P { get { void local(string x = nameof(p1)){} local(); return 0; } }"),
7733("2312", NotUsedWarning, "static int P { set { void local(string x = nameof(p1)){} local(); } }"),
7734("2313", NotUsedWarning, "static int P { set {} get { void local(string x = nameof(p1)){} local(); return 0; } }"),
7735("2314", NotUsedWarning, "static int P { get => 0; set { void local(string x = nameof(p1)){} local(); } }"),
7736("2315", NotUsedWarning, "static event System.Action E { add { void local(string x = nameof(p1)){} local(); } remove {} }"),
7737("2316", NotUsedWarning, "static event System.Action E { add {} remove { void local(string x = nameof(p1)){} local(); } }"),
7738("2317", NotUsedWarning, "void M() { void local(string x = nameof(p1)){} local(); }"),
7739("2318", NotUsedWarning, "int P { get { void local(string x = nameof(p1)){} local(); return 0; } }"),
7740("2319", NotUsedWarning, "int P { set { void local(string x = nameof(p1)){} local(); } }"),
7741("2320", NotUsedWarning, "int P { set {} get { void local(string x = nameof(p1)){} local(); return 0; } }"),
7742("2321", NotUsedWarning, "int P { get => 0; set { void local(string x = nameof(p1)){} local(); } }"),
7743("2322", NotUsedWarning, "event System.Action E { add { void local(string x = nameof(p1)){} local(); } remove {} }"),
7744("2323", NotUsedWarning, "event System.Action E { add {} remove { void local(string x = nameof(p1)){} local(); } }"),
7745("2324", NotUsedWarning, "int this[int x] { get { void local(string x = nameof(p1)){} local(); return 0; } }"),
7746("2325", NotUsedWarning, "int this[int x] { set { void local(string x = nameof(p1)){} local(); } }"),
7747("2326", NotUsedWarning, "int this[int x] { set {} get { void local(string x = nameof(p1)){} local(); return 0; } }"),
7748("2327", NotUsedWarning, "int this[int x] { get => 0; set { void local(string x = nameof(p1)){} local(); } }"),
7749("2328", NotUsedWarning, "~C1() { void local(string x = nameof(p1)){} local(); }"),
7750("2329", NotUsedWarning, "public C1() : this(() => { void local(string x = nameof(p1)){} local(); }) {} C1(System.Action x) : this(0) {}"),
7751("2330", NotUsedWarning, "public C1() : this(0) { void local(string x = nameof(p1)){} local(); }"),
7752("2335", NotUsedWarning, "class Nested() : NestedBase(() => { void local(string x = nameof(p1)){} local(); }) {} class NestedBase(System.Action x) { object F = x; } "),
7758("2404", NotUsedWarning | Shadows, "public static int F = nameof(p1).Length;"),
7759("2405", NotUsedWarning | Shadows, "public const string F = nameof(p1);"),
7760("2406", NotUsedWarning | Shadows, "public static int P {get;} = nameof(p1).Length;"),
7761("2407", NotUsedWarning | Shadows, "public static event System.Action E = () => nameof(p1).Length.ToString();"),
7762("2408", NotUsedWarning, "static C1() { _ = nameof(p1); }"),
7763("2409", NotUsedWarning, "static void M() { _ = nameof(p1); }"),
7764("2411", NotUsedWarning, "static int P { get { return nameof(p1).Length; } }"),
7765("2412", NotUsedWarning, "static int P { set { _ = nameof(p1); } }"),
7766("2413", NotUsedWarning, "static int P { set {} get { return nameof(p1).Length; } }"),
7767("2414", NotUsedWarning, "static int P { get => 0; set { _ = nameof(p1); } }"),
7768("2415", NotUsedWarning, "static event System.Action E { add { _ = nameof(p1); } remove {} }"),
7769("2416", NotUsedWarning, "static event System.Action E { add {} remove { _ = nameof(p1); } }"),
7770("2417", NotUsedWarning, "void M() { _ = nameof(p1); }"),
7771("2418", NotUsedWarning, "int P { get { return nameof(p1).Length; } }"),
7772("2419", NotUsedWarning, "int P { set { _ = nameof(p1); } }"),
7773("2420", NotUsedWarning, "int P { set {} get { return nameof(p1).Length; } }"),
7774("2421", NotUsedWarning, "int P { get => 0; set { _ = nameof(p1); } }"),
7775("2422", NotUsedWarning, "event System.Action E { add { _ = nameof(p1); } remove {} }"),
7776("2423", NotUsedWarning, "event System.Action E { add {} remove { _ = nameof(p1); } }"),
7777("2424", NotUsedWarning, "int this[int x] { get { return nameof(p1).Length; } }"),
7778("2425", NotUsedWarning, "int this[int x] { set { _ = nameof(p1); } }"),
7779("2426", NotUsedWarning, "int this[int x] { set {} get { return nameof(p1).Length; } }"),
7780("2427", NotUsedWarning, "int this[int x] { get => 0; set { _ = nameof(p1); } }"),
7781("2428", NotUsedWarning, "~C1() { _ = nameof(p1); }"),
7782("2429", NotUsedWarning, "public C1() : this(nameof(p1).Length) {}"),
7785("2501", NotUsedWarning, "class Nested { public int F = nameof(p1).Length; }"),
7786("2502", NotUsedWarning, "class Nested { public int P {get;} = nameof(p1).Length; }"),
7787("2503", NotUsedWarning, "class Nested { public event System.Action E = () => nameof(p1).Length.ToString(); }"),
7788("2504", NotUsedWarning, "class Nested { public static int F = nameof(p1).Length; }"),
7789("2506", NotUsedWarning, "class Nested { public static int P {get;} = nameof(p1).Length; }"),
7790("2507", NotUsedWarning, "class Nested { public static event System.Action E = () => nameof(p1).Length.ToString(); }"),
7791("2508", NotUsedWarning, "class Nested { static Nested() { _ = nameof(p1); } }"),
7792("2509", NotUsedWarning, "class Nested { static void M() { _ = nameof(p1); } }"),
7793("2511", NotUsedWarning, "class Nested { static int P { get { return nameof(p1).Length; } } }"),
7794("2512", NotUsedWarning, "class Nested { static int P { set { _ = nameof(p1); } } }"),
7795("2513", NotUsedWarning, "class Nested { static int P { set {} get { return nameof(p1).Length; } } }"),
7796("2514", NotUsedWarning, "class Nested { static int P { get => 0; set { _ = nameof(p1); } } }"),
7797("2515", NotUsedWarning, "class Nested { static event System.Action E { add { _ = nameof(p1); } remove {} } }"),
7798("2516", NotUsedWarning, "class Nested { static event System.Action E { add {} remove { _ = nameof(p1); } } }"),
7799("2517", NotUsedWarning, "class Nested { void M() { _ = nameof(p1); } }"),
7800("2518", NotUsedWarning, "class Nested { int P { get { return nameof(p1).Length; } } }"),
7801("2519", NotUsedWarning, "class Nested { int P { set { _ = nameof(p1); } } }"),
7802("2520", NotUsedWarning, "class Nested { int P { set {} get { return nameof(p1).Length; } } }"),
7803("2521", NotUsedWarning, "class Nested { int P { get => 0; set { _ = nameof(p1); } } }"),
7804("2522", NotUsedWarning, "class Nested { event System.Action E { add { _ = nameof(p1); } remove {} } }"),
7805("2523", NotUsedWarning, "class Nested { event System.Action E { add {} remove { _ = nameof(p1); } } }"),
7806("2524", NotUsedWarning, "class Nested { int this[int x] { get { return nameof(p1).Length; } } }"),
7807("2525", NotUsedWarning, "class Nested { int this[int x] { set { _ = nameof(p1); } } }"),
7808("2526", NotUsedWarning, "class Nested { int this[int x] { set {} get { return nameof(p1).Length; } } }"),
7809("2527", NotUsedWarning, "class Nested { int this[int x] { get => 0; set { _ = nameof(p1); } } }"),
7810("2528", NotUsedWarning, "class Nested { ~Nested() { _ = nameof(p1); } }"),
7811("2529", NotUsedWarning, "class Nested { public Nested() : this(nameof(p1).Length) {} Nested(int x) {} }"),
7812("2530", NotUsedWarning, "class Nested { public Nested() { _ = nameof(p1); } }"),
7928Assert.Equal((TestFlags)0, flags & TestFlags.NotUsedWarning);
7996if (!isRecord && (flags & TestFlags.NotUsedWarning) != 0)
8099if (!isRecord && ((flags & TestFlags.NotUsedWarning) != 0 || (flags & TestFlags.Captured) != 0))
8169("0001", BadReference | BadAttributeValue | NotUsedWarning, "[Attr1(p1)]"),
8170("0002", NotUsedWarning, "[Attr1(nameof(p1))]"),
8273("0001", NotInScope | NotUsedWarning, "[Attr1(p1)]"),
8274("0002", NotUsedWarning | Shadows, "[Attr1(nameof(p1))]"),
8352("0001", NotInScope | NotUsedWarning, "p1"),
8353("0002", NotInScope | NotUsedWarning, "nameof(p1)"),