21 references to InNestedMethod
Microsoft.CodeAnalysis.CSharp.Emit3.UnitTests (21)
Semantics\PrimaryConstructorTests.cs (21)
7359("1101", Captured | BadReference | InNestedMethod, "public C1() : this(() => p1) {} C1(System.Func<int> x) : this(0) {}"), 7360("1102", Captured | BadReference | InNestedMethod, "public C1() : this(() => (System.Func<int>)(() => p1)) {} C1(System.Func<System.Func<int>> x) : this(0) {}"), 7361("1103", Captured | BadReference | InNestedMethod, "public C1() : this(() => { return local(); int local() => p1; }) {} C1(System.Func<int> x) : this(0) {}"), 7371("1409", Captured | InNestedMethod, "public System.Func<int> M() { return (() => p1); }"), 7372("1410", Captured | InNestedMethod, "public System.Func<System.Func<int>> M() { return (() => (System.Func<int>)(() => p1)); }"), 7373("1411", Captured | InNestedMethod, "public System.Func<int> M() { return () => { return local(); int local() => p1; }; }"), 7374("1412", Captured | InNestedMethod, "public void M() { local(); int local() { return p1; } }"), 7375("1413", Captured | InNestedMethod, "public void M() { local1(); void local1() { local2(); int local2() { return p1; } } }"), 7694yield return new object[] { keyword, /*shadow:*/ false, isPartial, isRecord, "10003", Captured | BadReference | InNestedMethod, "public C1() : this(0) { local(); int local() { return p1; } }" }; 7695yield return new object[] { keyword, /*shadow:*/ true, isPartial, isRecord, "10004", Captured | InNestedMethod, "public C1() : this(0) { local(); int local() { return p1; } }" }; 7697yield return new object[] { keyword, /*shadow:*/ false, isPartial, isRecord, "10005", Captured | BadReference | InNestedMethod, "public C1() : this(0) { local1(); void local1() { local2(); int local2() { return p1; } } }" }; 7698yield return new object[] { keyword, /*shadow:*/ true, isPartial, isRecord, "10006", Captured | InNestedMethod, "public C1() : this(0) { local1(); void local1() { local2(); int local2() { return p1; } } }" }; 7700yield return new object[] { keyword, /*shadow:*/ false, isPartial, isRecord, "10007", Captured | BadReference | InNestedMethod, "public C1() : this(0) => M(() => p1); void M(System.Func<int> x){}" }; 7701yield return new object[] { keyword, /*shadow:*/ true, isPartial, isRecord, "10008", Captured | InNestedMethod, "public C1() : this(0) => M(() => p1); void M(System.Func<int> x){}" }; 7703yield return new object[] { keyword, /*shadow:*/ false, isPartial, isRecord, "10009", Captured | BadReference | InNestedMethod, "public C1() : this(0) => M(() => (System.Func<int>)(() => p1)); void M(System.Func<System.Func<int>> x){}" }; 7704yield return new object[] { keyword, /*shadow:*/ true, isPartial, isRecord, "10010", Captured | InNestedMethod, "public C1() : this(0) => M(() => (System.Func<int>)(() => p1)); void M(System.Func<System.Func<int>> x){}" }; 7706yield return new object[] { keyword, /*shadow:*/ false, isPartial, isRecord, "10011", Captured | BadReference | InNestedMethod, "public C1() : this(0) => M(() => { return local(); int local() => p1; }); void M(System.Func<int> x){}" }; 7707yield return new object[] { keyword, /*shadow:*/ true, isPartial, isRecord, "10012", Captured | InNestedMethod, "public C1() : this(0) => M(() => { return local(); int local() => p1; }); void M(System.Func<int> x){}" }; 7900if ((flags & (TestFlags.InNestedMethod)) != 0 && (flags & TestFlags.BadReference) == 0 && keyword == "struct") 7933(flags & (TestFlags.InNestedMethod)) == 0 && keyword == "struct" && 7948if ((flags & (TestFlags.InNestedMethod)) != 0 && keyword == "struct" &&