166 references to NotNullAttributeDefinition
Microsoft.CodeAnalysis.CSharp.Emit3.UnitTests (17)
FieldKeywordTests.cs (12)
6541var comp = CreateCompilation([source, NotNullAttributeDefinition]); 6565var comp = CreateCompilation([source, NotNullAttributeDefinition]); 6584var comp = CreateCompilation([source, NotNullAttributeDefinition, DisallowNullAttributeDefinition]); 6606var comp = CreateCompilation([source, NotNullAttributeDefinition]); 6625var comp = CreateCompilation([source, NotNullAttributeDefinition]); 6647var comp = CreateCompilation([source, NotNullAttributeDefinition]); 6670var comp = CreateCompilation([source, NotNullAttributeDefinition]); 6689var comp = CreateCompilation([source, NotNullAttributeDefinition]); 6714var comp = CreateCompilation([source, NotNullAttributeDefinition]); 6739var comp = CreateCompilation([source, NotNullAttributeDefinition]); 7227var comp = CreateCompilation(new[] { source, NotNullAttributeDefinition }); 7269var comp = CreateCompilation(new[] { source, AllowNullAttributeDefinition, NotNullAttributeDefinition, MaybeNullAttributeDefinition });
Semantics\RecordTests.cs (5)
310var comp = CreateCompilation(new[] { src, NotNullAttributeDefinition }); 356var comp = CreateCompilation(new[] { src, NotNullAttributeDefinition }); 392var comp = CreateCompilation(new[] { src, NotNullAttributeDefinition }); 9441var comp = CreateCompilation(new[] { src, NotNullAttributeDefinition }); 25563var comp = CreateCompilation(new[] { source, IsExternalInitTypeDefinition, NotNullAttributeDefinition }, parseOptions: TestOptions.Regular9);
Microsoft.CodeAnalysis.CSharp.Semantic.UnitTests (149)
Semantics\LambdaTests.cs (6)
4206new[] { source, MaybeNullAttributeDefinition, NotNullAttributeDefinition, NotNullIfNotNullAttributeDefinition, MemberNotNullAttributeDefinition, MemberNotNullWhenAttributeDefinition }, 4238var comp = CreateCompilation(new[] { source, MaybeNullAttributeDefinition, NotNullAttributeDefinition }, parseOptions: TestOptions.RegularPreview); 4285var comp = CreateCompilation(new[] { source, MaybeNullAttributeDefinition, NotNullAttributeDefinition }); 4359var comp = CreateCompilation(new[] { source, MaybeNullAttributeDefinition, NotNullAttributeDefinition }); 4406var comp = CreateCompilation(new[] { source, MaybeNullAttributeDefinition, NotNullAttributeDefinition }); 4639var comp = CreateCompilation(new[] { source, NotNullIfNotNullAttributeDefinition, NotNullAttributeDefinition });
Semantics\NullableReferenceTypesTests.cs (142)
20667", NotNullAttributeDefinition }, options: WithNullableEnable()); 20713", NotNullAttributeDefinition }, options: WithNullableEnable()); 29043", NotNullAttributeDefinition }); 29089", NotNullAttributeDefinition }); 29477var comp = CreateNullableCompilation(new[] { source, NotNullAttributeDefinition }); 29507var comp = CreateNullableCompilation(new[] { source, NotNullAttributeDefinition }); 29536var comp = CreateNullableCompilation(new[] { source, NotNullAttributeDefinition }); 29878", AllowNullAttributeDefinition, NotNullAttributeDefinition }); 30272var comp = CreateNullableCompilation(new[] { MaybeNullAttributeDefinition, NotNullAttributeDefinition, source }); 32767var comp = CreateNullableCompilation(new[] { source, NotNullAttributeDefinition }); 32799var comp = CreateNullableCompilation(new[] { source, NotNullAttributeDefinition, MemberNotNullAttributeDefinition, DisallowNullAttributeDefinition }); 32840var comp = CreateNullableCompilation(new[] { source, NotNullAttributeDefinition, MemberNotNullAttributeDefinition, DisallowNullAttributeDefinition }); 32912var comp = CreateNullableCompilation(new[] { source, NotNullAttributeDefinition, DisallowNullAttributeDefinition }); 32983var comp = CreateNullableCompilation(new[] { source, NotNullAttributeDefinition, DisallowNullAttributeDefinition }); 33075var comp = CreateNullableCompilation(new[] { source, NotNullAttributeDefinition }); 33117var comp = CreateNullableCompilation(new[] { source, NotNullAttributeDefinition, MaybeNullAttributeDefinition }); 34629var comp = CreateNullableCompilation(new[] { AllowNullAttributeDefinition, DisallowNullAttributeDefinition, NotNullAttributeDefinition, NotNullIfNotNullAttributeDefinition, source }); 34709var comp = CreateNullableCompilation(new[] { NotNullAttributeDefinition, MaybeNullAttributeDefinition, DisallowNullAttributeDefinition, source }); 34744", NotNullAttributeDefinition }, options: WithNullableEnable()); 34781", NotNullAttributeDefinition }, options: WithNullableEnable()); 36341", NotNullAttributeDefinition }, options: WithNullableEnable()); 36362", NotNullAttributeDefinition }, options: WithNullableEnable()); 36624" + NotNullAttributeDefinition); 38610", NotNullWhenAttributeDefinition, NotNullAttributeDefinition }, options: WithNullableEnable()); 38639", NotNullWhenAttributeDefinition, NotNullAttributeDefinition }, options: WithNullableEnable()); 38660", NotNullAttributeDefinition }, options: WithNullableEnable()); 38681", NotNullAttributeDefinition }, options: WithNullableEnable()); 38702", NotNullAttributeDefinition }, options: WithNullableEnable()); 38774", NotNullAttributeDefinition }, options: WithNullableEnable()); 38798", NotNullAttributeDefinition }, options: WithNullableEnable()); 38821", NotNullAttributeDefinition }, options: WithNullableEnable()); 38844", NotNullAttributeDefinition }, options: WithNullableEnable()); 38863" + NotNullAttributeDefinition); 38882", NotNullAttributeDefinition }, options: WithNullableEnable()); 38904", NotNullAttributeDefinition }, options: WithNullableEnable()); 38935", NotNullAttributeDefinition }, options: WithNullableEnable()); 38970", NotNullAttributeDefinition }, options: WithNullableEnable()); 38996", NotNullAttributeDefinition }, options: WithNullableEnable()); 39022", NotNullAttributeDefinition }, options: WithNullableEnable()); 39200", NotNullAttributeDefinition }, options: WithNullableEnable()); 39219" + NotNullAttributeDefinition); 39242", NotNullAttributeDefinition }, options: WithNullableEnable()); 39269", NotNullAttributeDefinition }, options: WithNullableEnable()); 39292", NotNullAttributeDefinition }, options: WithNullableEnable()); 39317", NotNullAttributeDefinition }, options: WithNullableEnable()); 39344", NotNullAttributeDefinition }, options: WithNullableEnable()); 39367", NotNullAttributeDefinition }, options: WithNullableEnable()); 39386", NotNullAttributeDefinition }, options: WithNullableEnable()); 39448", NotNullAttributeDefinition }, options: WithNullableEnable()); 39474", NotNullAttributeDefinition }, options: WithNullableEnable()); 39493", NotNullAttributeDefinition }, options: WithNullableEnable()); 39518", NotNullAttributeDefinition }, options: WithNullableEnable()); 39537", NotNullAttributeDefinition }, options: WithNullableEnable()); 39591new[] { source, DisallowNullAttributeDefinition, AllowNullAttributeDefinition, NotNullAttributeDefinition, MaybeNullAttributeDefinition }, 39662new[] { source, DisallowNullAttributeDefinition, AllowNullAttributeDefinition, NotNullAttributeDefinition, MaybeNullAttributeDefinition }, 39720new[] { source, DisallowNullAttributeDefinition, AllowNullAttributeDefinition, NotNullAttributeDefinition, MaybeNullAttributeDefinition }, 39786var comp = CreateCompilation(new[] { source, DisallowNullAttributeDefinition, AllowNullAttributeDefinition, NotNullAttributeDefinition, MaybeNullAttributeDefinition }); 39864new[] { source, DisallowNullAttributeDefinition, AllowNullAttributeDefinition, NotNullAttributeDefinition, MaybeNullAttributeDefinition }, 39902new[] { source, DisallowNullAttributeDefinition, AllowNullAttributeDefinition, NotNullAttributeDefinition, MaybeNullAttributeDefinition }, 39948new[] { source, DisallowNullAttributeDefinition, AllowNullAttributeDefinition, NotNullAttributeDefinition, MaybeNullAttributeDefinition }, 40000new[] { source, DisallowNullAttributeDefinition, AllowNullAttributeDefinition, NotNullAttributeDefinition, MaybeNullAttributeDefinition }, 40482var comp = CreateNullableCompilation(new[] { source, AllowNullAttributeDefinition, NotNullAttributeDefinition, MaybeNullAttributeDefinition }); 40503var comp = CreateNullableCompilation(new[] { source, AllowNullAttributeDefinition, NotNullAttributeDefinition, MaybeNullAttributeDefinition }); 41830var comp = CreateNullableCompilation(new[] { source, AllowNullAttributeDefinition, NotNullAttributeDefinition }); 42015var comp = CreateNullableCompilation(new[] { NotNullAttributeDefinition, source }); 42175var comp = CreateCompilation(new[] { NotNullAttributeDefinition, source }); 42227var comp = CreateCompilation(new[] { NotNullAttributeDefinition, source }); 42581var comp = CreateNullableCompilation(new[] { NotNullAttributeDefinition, NotNullWhenAttributeDefinition, source.Replace("TYPE", type) }); 42667var comp = CreateNullableCompilation(new[] { NotNullAttributeDefinition, NotNullWhenAttributeDefinition, source.Replace("CONSTRAINT", constraint) }); 42726var comp = CreateNullableCompilation(new[] { NotNullAttributeDefinition, source }); 42755var comp = CreateNullableCompilation(new[] { NotNullAttributeDefinition, source }); 42796var comp = CreateNullableCompilation(new[] { source, NotNullAttributeDefinition, DoesNotReturnIfAttributeDefinition }); 42846var comp = CreateNullableCompilation(new[] { MaybeNullWhenAttributeDefinition, NotNullAttributeDefinition, NotNullWhenAttributeDefinition, source.Replace("TYPE", type) }); 43244var comp = CreateNullableCompilation(new[] { NotNullAttributeDefinition, source }); 43348var comp = CreateNullableCompilation(new[] { NotNullAttributeDefinition, MaybeNullWhenAttributeDefinition, source }); 44881var comp = CreateNullableCompilation(new[] { source, AllowNullAttributeDefinition, MaybeNullAttributeDefinition, NotNullAttributeDefinition }, 44885var comp2 = CreateNullableCompilation(new[] { source, lib_cs, DisallowNullAttributeDefinition, AllowNullAttributeDefinition, MaybeNullAttributeDefinition, NotNullAttributeDefinition }); 44922var lib = CreateNullableCompilation(new[] { DisallowNullAttributeDefinition, AllowNullAttributeDefinition, MaybeNullAttributeDefinition, NotNullAttributeDefinition, lib_cs }); 44948var comp2 = CreateNullableCompilation(new[] { source, lib_cs, DisallowNullAttributeDefinition, AllowNullAttributeDefinition, MaybeNullAttributeDefinition, NotNullAttributeDefinition }); 45740var comp = CreateNullableCompilation(new[] { MaybeNullAttributeDefinition, NotNullAttributeDefinition, source }); 46099var comp = CreateCompilation(new[] { MaybeNullAttributeDefinition, NotNullAttributeDefinition, source }, options: WithNullableEnable()); 47304var comp = CreateCompilation(new[] { NotNullAttributeDefinition, source }, options: WithNullableEnable()); 47380var comp = CreateCompilation(new[] { NotNullAttributeDefinition, source }, options: WithNullableEnable()); 47426var comp = CreateCompilation(new[] { NotNullAttributeDefinition, source }, options: WithNullableEnable()); 47445var comp = CreateCompilation(new[] { NotNullAttributeDefinition, source }, options: WithNullableEnable()); 47459var comp = CreateCompilation(new[] { NotNullAttributeDefinition, source0 }, options: WithNullableEnable()); 47503var comp = CreateNullableCompilation(new[] { NotNullAttributeDefinition, source0 }); 47544var comp = CreateNullableCompilation(new[] { NotNullAttributeDefinition, MaybeNullAttributeDefinition, source0 }); 47596var comp = CreateNullableCompilation(new[] { NotNullAttributeDefinition, MaybeNullAttributeDefinition, source }); 47639var comp = CreateCompilation(new[] { NotNullAttributeDefinition, source }, options: WithNullableEnable()); 47663var lib = CreateNullableCompilation(new[] { lib_cs, NotNullAttributeDefinition }); 47692var comp2 = CreateNullableCompilation(new[] { source, lib_cs, NotNullAttributeDefinition }); 47729var comp = CreateNullableCompilation(new[] { lib_cs, NotNullAttributeDefinition }); 47779var comp = CreateNullableCompilation(new[] { lib_cs, NotNullAttributeDefinition }); 47802var comp = CreateNullableCompilation(new[] { lib_cs, NotNullAttributeDefinition }); 47822var comp = CreateNullableCompilation(new[] { source, NotNullAttributeDefinition }); 47850var comp = CreateNullableCompilation(new[] { source, NotNullAttributeDefinition }); 47888var comp = CreateNullableCompilation(new[] { source, NotNullAttributeDefinition }); 47918var comp = CreateNullableCompilation(new[] { source, NotNullAttributeDefinition }); 47948var lib = CreateNullableCompilation(new[] { lib_cs, NotNullAttributeDefinition }); 47975var comp2 = CreateNullableCompilation(new[] { source, lib_cs, NotNullAttributeDefinition }); 48029var comp = CreateNullableCompilation(new[] { source, NotNullAttributeDefinition }); 48059var lib = CreateNullableCompilation(new[] { NotNullAttributeDefinition, lib_cs }); 48085var comp2 = CreateNullableCompilation(new[] { source, lib_cs, NotNullAttributeDefinition }); 48124var comp = CreateNullableCompilation(new[] { source, NotNullAttributeDefinition }); 48150var comp = CreateNullableCompilation(new[] { source, NotNullAttributeDefinition }); 48238var comp = CreateNullableCompilation(new[] { NotNullAttributeDefinition, source }); 48288var comp = CreateNullableCompilation(new[] { NotNullAttributeDefinition, source }); 48333var comp = CreateNullableCompilation(new[] { NotNullAttributeDefinition, source }); 48373var comp = CreateNullableCompilation(new[] { NotNullAttributeDefinition, MaybeNullAttributeDefinition, source }); 48410var comp = CreateNullableCompilation(new[] { NotNullAttributeDefinition, MaybeNullAttributeDefinition, source }); 48475var comp = CreateNullableCompilation(new[] { NotNullAttributeDefinition, MaybeNullAttributeDefinition, source }); 48632var comp = CreateNullableCompilation(new[] { NotNullAttributeDefinition, source }); 48670var comp = CreateNullableCompilation(new[] { NotNullAttributeDefinition, source }); 48708var comp = CreateNullableCompilation(new[] { NotNullAttributeDefinition, source }); 48733var comp = CreateNullableCompilation(new[] { NotNullAttributeDefinition, MaybeNullWhenAttributeDefinition, source }); 48758var comp = CreateNullableCompilation(new[] { NotNullAttributeDefinition, MaybeNullWhenAttributeDefinition, source }); 48806var comp = CreateCompilation(new[] { MaybeNullAttributeDefinition, NotNullAttributeDefinition, source }, options: WithNullableEnable(), parseOptions: TestOptions.Regular8); 54038CreateNullableCompilation(new[] { source, NotNullAttributeDefinition }).VerifyDiagnostics( 68659var comp = CreateCompilation(new[] { code, handler, InterpolatedStringHandlerArgumentAttribute, NotNullAttributeDefinition }); 68861var comp = CreateCompilation(new[] { code, handler, InterpolatedStringHandlerArgumentAttribute, NotNullAttributeDefinition }); 68895var comp = CreateCompilation(new[] { code, handler, InterpolatedStringHandlerArgumentAttribute, NotNullAttributeDefinition }); 68926var comp = CreateCompilation(new[] { code, handler, InterpolatedStringHandlerArgumentAttribute, NotNullAttributeDefinition }); 68954var comp = CreateCompilation(new[] { code, handler, InterpolatedStringHandlerArgumentAttribute, NotNullAttributeDefinition }); 70125var comp = CreateNullableCompilation(new[] { source, AllowNullAttributeDefinition, NotNullAttributeDefinition }); 72272", MaybeNullAttributeDefinition, NotNullAttributeDefinition }); 91678var comp = CreateCompilation(new[] { source, NotNullAttributeDefinition }, options: WithNullableEnable()); 91887var comp = CreateCompilation(new[] { source, NotNullAttributeDefinition }, options: WithNullableEnable(), parseOptions: TestOptions.Regular9); 92124var comp = CreateCompilation(new[] { source, NotNullAttributeDefinition }, options: WithNullableEnable(), parseOptions: TestOptions.Regular9); 92391var comp = CreateCompilationWithTasksExtensions(new[] { source, s_IAsyncEnumerable, NotNullAttributeDefinition }, options: WithNullableEnable(), parseOptions: TestOptions.Regular9); 92631var comp = CreateCompilationWithTasksExtensions(new[] { source, s_IAsyncEnumerable, NotNullAttributeDefinition }, options: WithNullableEnable(), parseOptions: TestOptions.Regular9); 136963var comp = CreateCompilation(new[] { source, NotNullAttributeDefinition }, options: WithNullableEnable()); 140501var comp = CreateCompilation(new[] { NotNullAttributeDefinition, source }, options: WithNullableEnable()); 149658var comp = CreateCompilation(new[] { source, AllowNullAttributeDefinition, DisallowNullAttributeDefinition, NotNullAttributeDefinition }); 149723var comp = CreateCompilation(new[] { source, AllowNullAttributeDefinition, DisallowNullAttributeDefinition, MaybeNullAttributeDefinition, NotNullAttributeDefinition }); 149771var comp = CreateCompilation(new[] { source, AllowNullAttributeDefinition, DisallowNullAttributeDefinition, MaybeNullAttributeDefinition, NotNullAttributeDefinition }); 149808var comp = CreateCompilation(new[] { source, AllowNullAttributeDefinition, DisallowNullAttributeDefinition, MaybeNullAttributeDefinition, NotNullAttributeDefinition }); 149853var comp = CreateCompilation(new[] { source, AllowNullAttributeDefinition, DisallowNullAttributeDefinition, MaybeNullAttributeDefinition, NotNullAttributeDefinition }); 154968var comp = CreateCompilation(new[] { sourceA, DisallowNullAttributeDefinition, NotNullAttributeDefinition }); 155093comp = CreateCompilation(new[] { sourceB, DisallowNullAttributeDefinition, NotNullAttributeDefinition }, references: new[] { refA }); 155154comp = CreateCompilation(new[] { sourceB, DisallowNullAttributeDefinition, NotNullAttributeDefinition }, references: new[] { refA }); 158938var comp = CreateCompilation(new[] { source, MaybeNullAttributeDefinition, NotNullAttributeDefinition, DoesNotReturnAttributeDefinition, DoesNotReturnIfAttributeDefinition });
Semantics\OverloadResolutionPerfTests.cs (1)
287var comp = CreateCompilation(new[] { NotNullAttributeDefinition, source });