39 references to Annotated
Microsoft.CodeAnalysis.CSharp (39)
Binder\Binder_Constraints.cs (1)
555
if (typeWithAnnotations.NullableAnnotation == NullableAnnotation.
Annotated
&& performOnlyCycleSafeValidation &&
Binder\Binder_Expressions.cs (1)
1663
expression = new BoundDiscardExpression(node, NullableAnnotation.
Annotated
, isInferred: true, type: null);
FlowAnalysis\NullableWalker.cs (6)
2273
case NullableAnnotation.
Annotated
:
7901
return expr.ConstantValueOpt == ConstantValue.NotAvailable || !expr.ConstantValueOpt.IsNull || expr.IsSuppressed ? NullableAnnotation.NotAnnotated : NullableAnnotation.
Annotated
;
9166
return (annotation == NullableAnnotation.
Annotated
) ? NullableFlowState.MaybeDefault : NullableFlowState.MaybeNull;
9201
return (annotation == NullableAnnotation.
Annotated
) ? NullableFlowState.MaybeDefault : NullableFlowState.MaybeNull;
9242
var combinedAnnotation = NullableAnnotation.
Annotated
;
11954
var result = TypeWithAnnotations.Create(node.Type, node.IsInferred ? NullableAnnotation.
Annotated
: node.NullableAnnotation);
FlowAnalysis\NullableWalker_Patterns.cs (1)
839
var type = TypeWithAnnotations.Create(t, NullableAnnotation.
Annotated
);
Symbols\AliasSymbol.cs (1)
409
annotatedNamespaceOrType.TypeWithAnnotations.NullableAnnotation == NullableAnnotation.
Annotated
&&
Symbols\ConstraintsHelper.cs (4)
1212
case NullableAnnotation.
Annotated
:
1252
case NullableAnnotation.
Annotated
:
1609
case NullableAnnotation.
Annotated
:
1631
case NullableAnnotation.
Annotated
:
Symbols\NullableAnnotationExtensions.cs (4)
16
public static bool IsAnnotated(this NullableAnnotation annotation) => annotation == NullableAnnotation.
Annotated
;
82
/// The attribute (metadata) representation of <see cref="NullableAnnotation.
Annotated
"/>.
131
NullableAnnotation.
Annotated
=> CodeAnalysis.NullableAnnotation.Annotated,
153
CodeAnalysis.NullableAnnotation.Annotated => CSharp.NullableAnnotation.
Annotated
,
Symbols\Synthesized\Records\SynthesizedRecordBaseEquals.cs (1)
32
TypeWithAnnotations.Create(ContainingType.BaseTypeNoUseSiteDiagnostics, NullableAnnotation.
Annotated
),
Symbols\Synthesized\Records\SynthesizedRecordEqualityOperatorBase.cs (1)
68
var annotation = ContainingType.IsRecordStruct ? NullableAnnotation.Oblivious : NullableAnnotation.
Annotated
;
Symbols\Synthesized\Records\SynthesizedRecordEquals.cs (1)
36
var annotation = ContainingType.IsRecordStruct ? NullableAnnotation.Oblivious : NullableAnnotation.
Annotated
;
Symbols\Synthesized\Records\SynthesizedRecordObjEquals.cs (1)
31
var annotation = ContainingType.IsRecordStruct ? NullableAnnotation.Oblivious : NullableAnnotation.
Annotated
;
Symbols\TypeWithAnnotations.cs (15)
55
Debug.Assert(defaultType?.IsNullableType() != true || defaultAnnotation == NullableAnnotation.
Annotated
);
82
return Create(typeSymbol, nullableAnnotation: isAnnotated ? NullableAnnotation.
Annotated
: isNullableEnabled ? NullableAnnotation.NotAnnotated : NullableAnnotation.Oblivious);
100
nullableAnnotation = NullableAnnotation.
Annotated
;
115
return Create(Type, NullableAnnotation.
Annotated
, CustomModifiers);
138
return NullableAnnotation.
Annotated
;
143
return NullableAnnotation.
Annotated
;
156
case NullableAnnotation.
Annotated
:
175
return new TypeWithAnnotations(defaultType: underlying.DefaultType, defaultAnnotation: NullableAnnotation.
Annotated
, new LazyNullableTypeParameter(compilation, underlying));
204
return CreateNonLazyType(typeSymbol, NullableAnnotation.
Annotated
, this.CustomModifiers);
488
newAnnotation = NullableAnnotation.
Annotated
;
821
return annotation switch { NullableAnnotation.
Annotated
=> NullableFlowState.MaybeDefault, NullableAnnotation.NotAnnotated => NullableFlowState.MaybeNull, _ => NullableFlowState.NotNull };
825
return annotation switch { NullableAnnotation.
Annotated
=> NullableFlowState.MaybeDefault, _ => NullableFlowState.NotNull };
831
return annotation switch { NullableAnnotation.
Annotated
=> NullableFlowState.MaybeNull, _ => NullableFlowState.NotNull };
921
return CreateNonLazyType(type.DefaultType, NullableAnnotation.
Annotated
, _customModifiers);
1024
return CreateNonLazyType(type.DefaultType, NullableAnnotation.
Annotated
, _customModifiers);
Symbols\TypeWithState.cs (2)
93
(Type?.IsValueType == true ? NullableAnnotation.NotAnnotated : NullableAnnotation.
Annotated
) :
94
(State.IsNotNull() || Type?.CanContainNull() == false ? NullableAnnotation.NotAnnotated : NullableAnnotation.
Annotated
);