Binder\Binder_Expressions.cs (11)
358diagnostics.Add(ErrorCode.ERR_DefaultLiteralNoTargetType, defaultExpr.Syntax.GetLocation());
401diagnostics.Add(ErrorCode.ERR_CollectionExpressionNoTargetType, expr.Syntax.GetLocation());
427diagnostics.Add(ErrorCode.ERR_CannotInferDelegateType, syntax.GetLocation());
4927diagnostics.Add(ErrorCode.ERR_NoDynamicPhantomOnBaseCtor, errorLocation);
5071diagnostics.Add(ErrorCode.ERR_ChainingToSetsRequiredMembersRequiresSetsRequiredMembers, errorLocation);
5117diagnostics.Add(ErrorCode.ERR_CopyConstructorMustInvokeBaseCopyConstructor, errorLocation);
5126diagnostics.Add(ErrorCode.ERR_CopyConstructorMustInvokeBaseCopyConstructor, errorLocation);
5443diagnostics.Add(ErrorCode.ERR_MethodNameExpected, argument.Syntax.Location);
5504diagnostics.Add(ErrorCode.ERR_MethodNameExpected, argument.Syntax.Location);
5972diagnostics.Add(ErrorCode.ERR_InterpolatedStringsReferencingInstanceCannotBeInObjectInitializers, argument.Syntax.Location);
8999diagnostics.Add(ErrorCode.ERR_RuntimeDoesNotSupportRefFields, node.Location);
Symbols\Source\SourceMemberContainerSymbol.cs (16)
1961diagnostics.Add(ErrorCode.ERR_CloneDisallowedInRecord, member.GetFirstLocation());
2313diagnostics.Add(ErrorCode.ERR_InconsistentIndexerNames, indexer.GetFirstLocation());
2962diagnostics.Add(ErrorCode.ERR_ScriptsAndSubmissionsCannotHaveRequiredMembers, member.GetFirstLocation());
4143diagnostics.Add(ErrorCode.ERR_PartialMethodOnlyOneActual, currentMethod.GetFirstLocation());
4149diagnostics.Add(ErrorCode.ERR_PartialMethodOnlyOneLatent, currentMethod.GetFirstLocation());
4162diagnostics.Add(ErrorCode.ERR_PartialPropertyDuplicateImplementation, currentProperty.GetFirstLocation());
4167diagnostics.Add(ErrorCode.ERR_PartialPropertyDuplicateDefinition, currentProperty.GetFirstLocation());
4173diagnostics.Add(ErrorCode.ERR_PartialPropertyDuplicateInitializer, currentProperty.GetFirstLocation());
4605diagnostics.Add(ErrorCode.ERR_InterfacesCantContainConstructors, member.GetFirstLocation());
4612diagnostics.Add(ErrorCode.ERR_OnlyClassesCanContainDestructors, member.GetFirstLocation());
4653diagnostics.Add(ErrorCode.ERR_ExtensionDisallowsMember, member.GetFirstLocation());
4718diagnostics.Add(ErrorCode.ERR_EnumsCantContainDefaultConstructor, location);
4725diagnostics.Add(ErrorCode.ERR_NonPublicParameterlessStructConstructor, location);
4757diagnostics.Add(ErrorCode.ERR_StructHasInitializersAndNoDeclaredConstructor, GetFirstLocation());
4974diagnostics.Add(ErrorCode.ERR_RecordAmbigCtor, copyCtor.GetFirstLocation());
4983diagnostics.Add(ErrorCode.ERR_RecordAmbigCtor, this.GetFirstLocation());
Symbols\Source\SourceMethodSymbolWithAttributes.cs (10)
1138diagnostics.Add(ErrorCode.ERR_InterceptorGlobalNamespace, attributeLocation);
1158diagnostics.Add(ErrorCode.WRN_InterceptsLocationAttributeUnsupportedSignature, attributeLocation);
1358diagnostics.Add(ErrorCode.ERR_InterceptorMethodMustBeOrdinary, attributeLocation);
1366diagnostics.Add(ErrorCode.ERR_InterceptorCannotUseUnmanagedCallersOnly, attributeLocation);
1405diagnostics.Add(ErrorCode.ERR_CannotUseRefInUnmanagedCallersOnly, syntax.Location);
1480diagnostics.Add(ErrorCode.ERR_ComImportWithUserCtor, this.GetFirstLocation());
1541diagnostics.Add(ErrorCode.ERR_BadAsyncReturn, errorLocation);
1561diagnostics.Add(ErrorCode.ERR_SecurityCriticalOrSecuritySafeCriticalOnAsyncInClassOrStruct, errorLocation);
1570diagnostics.Add(ErrorCode.ERR_SynchronizedAsyncMethod, errorLocation);
1596diagnostics.Add(ErrorCode.ERR_MultipleEnumeratorCancellationAttributes, errorLocation);
Symbols\Source\SourceNamedTypeSymbol.cs (10)
1877diagnostics.Add(ErrorCode.ERR_InvalidInlineArrayLayout, GetFirstLocation());
1886diagnostics.Add(ErrorCode.ERR_InlineArrayUnsupportedElementFieldModifier, elementField.TryGetFirstLocation() ?? GetFirstLocation());
1900diagnostics.Add(ErrorCode.WRN_InlineArrayIndexerNotUsed, indexer.TryGetFirstLocation() ?? GetFirstLocation());
1908diagnostics.Add(ErrorCode.WRN_InlineArraySliceNotUsed, slice.TryGetFirstLocation() ?? GetFirstLocation());
1931diagnostics.Add(ErrorCode.WRN_InlineArrayConversionOperatorNotUsed, conversion.TryGetFirstLocation() ?? GetFirstLocation());
1940diagnostics.Add(ErrorCode.WRN_InlineArrayNotSupportedByLanguage, elementField.TryGetFirstLocation() ?? GetFirstLocation());
1944diagnostics.Add(ErrorCode.WRN_InlineArrayNotSupportedByLanguage, GetFirstLocation());
1950diagnostics.Add(ErrorCode.ERR_InvalidInlineArrayFields, GetFirstLocation());
1955diagnostics.Add(ErrorCode.ERR_RuntimeDoesNotSupportInlineArrayTypes, GetFirstLocation());
1982diagnostics.Add(ErrorCode.ERR_EmbeddedAttributeMustFollowPattern, GetFirstLocation());
Symbols\Source\SourceOrdinaryMethodSymbol.cs (15)
243diagnostics.Add(ErrorCode.ERR_BadExtensionMeth, _location);
492diagnostics.Add(ErrorCode.ERR_PartialMethodReturnTypeDifference, implementation.GetFirstLocation());
502diagnostics.Add(ErrorCode.ERR_PartialMemberRefReturnDifference, implementation.GetFirstLocation());
507diagnostics.Add(ErrorCode.ERR_PartialMemberStaticDifference, implementation.GetFirstLocation());
512diagnostics.Add(ErrorCode.ERR_PartialMemberReadOnlyDifference, implementation.GetFirstLocation());
517diagnostics.Add(ErrorCode.ERR_PartialMethodExtensionDifference, implementation.GetFirstLocation());
522diagnostics.Add(ErrorCode.ERR_PartialMemberUnsafeDifference, implementation.GetFirstLocation());
527diagnostics.Add(ErrorCode.ERR_PartialMemberParamsDifference, implementation.GetFirstLocation());
533diagnostics.Add(ErrorCode.ERR_PartialMemberAccessibilityDifference, implementation.GetFirstLocation());
541diagnostics.Add(ErrorCode.ERR_PartialMemberExtendedModDifference, implementation.GetFirstLocation());
569diagnostics.Add(ErrorCode.WRN_NullabilityMismatchInReturnTypeOnPartial, implementingMethod.GetFirstLocation());
835diagnostics.Add(ErrorCode.ERR_PartialMemberCannotBeAbstract, location);
912diagnostics.Add(ErrorCode.ERR_BadAsyncLacksBody, location);
928diagnostics.Add(ErrorCode.ERR_BadVarargs, location);
932diagnostics.Add(ErrorCode.ERR_VarargsAsync, location);
Symbols\Source\SourcePropertySymbol.cs (13)
608diagnostics.Add(ErrorCode.ERR_IndexerCantHaveVoidType, Location);
642diagnostics.Add(ErrorCode.ERR_IllegalVarArgs, arglistToken.GetLocation());
699diagnostics.Add(ErrorCode.ERR_ValueParameterSameNameAsExtensionTypeParameter, setter.GetFirstLocationOrNone());
704diagnostics.Add(ErrorCode.ERR_ValueParameterSameNameAsExtensionParameter, setter.GetFirstLocationOrNone());
738diagnostics.Add(ErrorCode.ERR_PartialMemberTypeDifference, implementation.GetFirstLocation());
749diagnostics.Add(ErrorCode.ERR_PartialMemberRefReturnDifference, implementation.GetFirstLocation());
762diagnostics.Add(ErrorCode.ERR_PartialPropertyRequiredDifference, implementation.GetFirstLocation());
767diagnostics.Add(ErrorCode.ERR_PartialMemberStaticDifference, implementation.GetFirstLocation());
772diagnostics.Add(ErrorCode.ERR_PartialMemberReadOnlyDifference, implementation.GetFirstLocation());
777diagnostics.Add(ErrorCode.ERR_PartialMemberUnsafeDifference, implementation.GetFirstLocation());
782diagnostics.Add(ErrorCode.ERR_PartialMemberParamsDifference, implementation.GetFirstLocation());
788diagnostics.Add(ErrorCode.ERR_PartialMemberAccessibilityDifference, implementation.GetFirstLocation());
796diagnostics.Add(ErrorCode.ERR_PartialMemberExtendedModDifference, implementation.GetFirstLocation());
Symbols\Source\SourcePropertySymbolBase.cs (13)
309diagnostics.Add(ErrorCode.ERR_InstancePropertyInitializerInInterface, Location);
313diagnostics.Add(ErrorCode.ERR_InitializerOnNonAutoProperty, Location);
884diagnostics.Add(ErrorCode.ERR_RefReturningPropertiesCannotBeRequired, Location);
893diagnostics.Add(ErrorCode.ERR_AutoPropsInRoStruct, Location);
907diagnostics.Add(ErrorCode.ERR_AutoPropertyCannotBeRefReturning, Location);
917diagnostics.Add(ErrorCode.ERR_AutoPropertyMustOverrideSet, Location);
929diagnostics.Add(ErrorCode.ERR_InterfacesCantContainFields, Location);
944diagnostics.Add(ErrorCode.ERR_RefPropertyCannotHaveSetAccessor, _setMethod.GetFirstLocation());
973diagnostics.Add(ErrorCode.ERR_RefPropertyMustHaveGetAccessor, Location);
981diagnostics.Add(ErrorCode.ERR_AutoPropertyMustHaveGetAccessor, _setMethod!.GetFirstLocation());
1105diagnostics.Add(ErrorCode.ERR_PartialMemberOnlyInPartialClass, location);
1109diagnostics.Add(ErrorCode.ERR_PartialMemberNotExplicit, location);
1113diagnostics.Add(ErrorCode.ERR_PartialMemberCannotBeAbstract, location);
Symbols\Source\SourceUserDefinedOperatorSymbolBase.cs (16)
67diagnostics.Add(ErrorCode.ERR_InterfacesCantContainConversionOrEqualityOperators, this.GetFirstLocation());
83diagnostics.Add(ErrorCode.ERR_OperatorInExtensionOfStaticClass, location);
410diagnostics.Add(ErrorCode.ERR_InstanceOperatorStructExtensionWrongReceiverRefKind, _location);
419diagnostics.Add(ErrorCode.ERR_InstanceOperatorStructExtensionWrongReceiverRefKind, _location);
423diagnostics.Add(ErrorCode.ERR_InstanceOperatorExtensionWrongReceiverType, _location);
475diagnostics.Add(ErrorCode.ERR_IllegalRefParam, this.GetFirstLocation());
565diagnostics.Add(ErrorCode.ERR_OperatorMustReturnVoid, this.GetFirstLocation());
662diagnostics.Add(IsInInterfaceAndAbstractOrVirtual() ? ErrorCode.ERR_AbstractConversionNotInvolvingContainedType : ErrorCode.ERR_ConversionNotInvolvingContainedType, this.GetFirstLocation());
673diagnostics.Add(ErrorCode.ERR_IdentityConversion, this.GetFirstLocation());
786diagnostics.Add(ErrorCode.ERR_OperatorCantReturnVoid, this.GetFirstLocation());
804diagnostics.Add(IsInInterfaceAndAbstractOrVirtual() ?
821diagnostics.Add(ErrorCode.ERR_OpTFRetType, this.GetFirstLocation());
873diagnostics.Add(IsInInterfaceAndAbstractOrVirtual() ?
887diagnostics.Add(IsInInterfaceAndAbstractOrVirtual() ? ErrorCode.ERR_BadAbstractIncDecRetType : ErrorCode.ERR_BadIncDecRetType, this.GetFirstLocation());
948diagnostics.Add(IsInInterfaceAndAbstractOrVirtual() ?
970diagnostics.Add(IsInInterfaceAndAbstractOrVirtual() ?