Base:
property
ContainingType
Microsoft.CodeAnalysis.CSharp.Symbol.ContainingType
39 references to ContainingType
Microsoft.CodeAnalysis.CSharp (39)
Binder\Binder_Statements.cs (1)
1785
TypeSymbol.Equals(sourceProperty.
ContainingType
, fromMember.ContainingType, TypeCompareKind.AllIgnoreOptions) &&
Compiler\MethodCompiler.cs (1)
864
_moduleBeingBuiltOpt.AddSynthesizedDefinition(sourceProperty.
ContainingType
, synthesizedAccessor.GetCciAdapter());
Compiler\SynthesizedMetadataCompiler.cs (1)
111
_moduleBeingBuilt.AddSynthesizedDefinition(sourceProperty.
ContainingType
, synthesizedAccessor.GetCciAdapter());
Symbols\Source\SourcePropertySymbol.cs (6)
521
ContainingType
,
534
ContainingType
,
577
if (type.Type.HasFileLocalTypes() && !
ContainingType
.HasFileLocalTypes())
579
diagnostics.Add(ErrorCode.ERR_FileTypeDisallowedInSignature, Location, type.Type,
ContainingType
);
659
else if (param.Type.HasFileLocalTypes() && !this.
ContainingType
.HasFileLocalTypes())
661
diagnostics.Add(ErrorCode.ERR_FileTypeDisallowedInSignature, Location, param.Type, this.
ContainingType
);
Symbols\Source\SourcePropertySymbolBase.cs (23)
306
if (
ContainingType
.IsInterface && !IsStatic)
794
if (!IsStatic &&
ContainingType
.IsReadOnly)
868
if (
ContainingType
.IsReadOnly)
890
var overriddenProperty = (PropertySymbol)this.GetLeastOverriddenMember(this.
ContainingType
);
900
ContainingType
.IsInterface &&
1014
TypeSymbol.CheckModifierMismatchOnImplementingMember(this.
ContainingType
, this, explicitlyImplementedProperty, isExplicit: true, diagnostics);
1052
Debug.Assert(!IsStatic ||
ContainingType
.IsInterface || (!IsAbstract && !IsVirtual)); // Otherwise should have been reported and cleared earlier.
1054
bool isExplicitInterfaceImplementationInInterface = isExplicitInterfaceImplementation &&
ContainingType
.IsInterface;
1075
else if (IsPartial && !
ContainingType
.IsPartial())
1087
else if (IsAbstract &&
ContainingType
.TypeKind == TypeKind.Struct)
1092
else if (IsVirtual &&
ContainingType
.TypeKind == TypeKind.Struct)
1109
else if (
ContainingType
.IsSealed && this.DeclaredAccessibility.HasProtected() && !this.IsOverride)
1111
diagnostics.Add(AccessCheck.GetProtectedMemberInSealedTypeError(
ContainingType
), location, this);
1113
else if (
ContainingType
.IsStatic && !IsStatic)
1382
AddSynthesizedAttribute(ref attributes, moduleBuilder.SynthesizeNullableAttributeIfNecessary(this,
ContainingType
.GetNullableContextValue(), type));
1555
CSharpAttributeData.DecodeMemberNotNullAttribute<PropertyWellKnownAttributeData>(
ContainingType
, ref arguments);
1560
CSharpAttributeData.DecodeMemberNotNullWhenAttribute<PropertyWellKnownAttributeData>(
ContainingType
, ref arguments);
1573
if (
ContainingType
.IsInterface || IsExplicitInterfaceImplementation)
1837
if (!this.IsStatic && (
ContainingType
.IsRecord ||
ContainingType
.IsRecordStruct) && type.IsPointerOrFunctionPointer())
1842
else if (type.IsRefLikeOrAllowsRefLikeType() && (this.IsStatic || !this.
ContainingType
.IsRefLikeType))
1853
diagnostics.Add(ErrorFacts.GetStaticClassReturnCode(
ContainingType
.IsInterfaceType()), TypeLocation, type);
1858
diagnostics.Add(ErrorFacts.GetStaticClassParameterCode(
ContainingType
.IsInterfaceType()), TypeLocation, type);
Symbols\Synthesized\Records\SynthesizedRecordEqualityContractProperty.cs (4)
62
=>
ContainingType
.GetFirstLocation();
67
ContainingType
,
70
ContainingType
.GetFirstLocation(),
71
(CSharpSyntaxNode)((SourceMemberContainerTypeSymbol)
ContainingType
).SyntaxReferences[0].GetSyntax(),
Symbols\Synthesized\Records\SynthesizedRecordPropertySymbol.cs (2)
81
var usesInit = !isGet && ShouldUseInit(
ContainingType
);
85
ContainingType
,
Symbols\Synthesized\SynthesizedBackingFieldSymbol.cs (1)
152
=> _property.
ContainingType
;