1 write to Kind
illink (1)
Linker\DependencyInfo.cs (1)
154
public DependencyInfo(DependencyKind kind, object? source) => (
Kind
, Source) = (kind, source);
37 references to Kind
illink (37)
Linker.Steps\MarkStep.cs (29)
321
if (!_entireTypeReasons.Contains(reason.
Kind
))
322
throw new InternalErrorException($"Unsupported type dependency '{reason.
Kind
}'.");
1682
Debug.Assert(reason.
Kind
== DependencyKind.FieldAccess || reason.
Kind
== DependencyKind.Ldtoken);
1806
if (!_fieldReasons.Contains(reason.
Kind
))
1807
throw new ArgumentOutOfRangeException($"Internal error: unsupported field dependency {reason.
Kind
}");
1810
if (reason.
Kind
== DependencyKind.AlreadyMarked)
1819
ProcessAnalysisAnnotationsForField(field, reason.
Kind
, in origin);
1856
var cctorReason = reason.
Kind
switch
1917
if (reason.
Kind
== DependencyKind.AlreadyMarked)
2052
if (!_typeReasons.Contains(reason.
Kind
))
2053
throw new ArgumentOutOfRangeException($"Internal error: unsupported type dependency {reason.
Kind
}");
2072
switch (reason.
Kind
)
2083
if (type.HasMethods && ShouldMarkTypeStaticConstructor(type) && reason.
Kind
== DependencyKind.DeclaringTypeOfCalledMethod)
2094
reason.
Kind
is not DependencyKind.TypeInAssembly)
2202
if (ShouldMarkTypeStaticConstructor(type) && reason.
Kind
!= DependencyKind.TriggersCctorForCalledMethod)
3150
ProcessAnalysisAnnotationsForMethod(method, originalReason.
Kind
, origin);
3153
switch (reason.
Kind
)
3164
reason.
Kind
== DependencyKind.DirectCall ||
3165
reason.
Kind
== DependencyKind.VirtualCall ||
3166
reason.
Kind
== DependencyKind.Newobj;
3178
&& reason.
Kind
!= DependencyKind.EventMethod)
3180
var kind = PropagateDependencyKindToAccessors(reason.
Kind
, DependencyKind.EventOfEventMethod);
3314
if (!_methodReasons.Contains(reason.
Kind
))
3315
throw new InternalErrorException($"Unsupported method dependency {reason.
Kind
}");
3320
reason.
Kind
== DependencyKind.DirectCall ||
3321
reason.
Kind
== DependencyKind.VirtualCall ||
3322
reason.
Kind
== DependencyKind.Newobj;
3350
MarkProperty(property, new DependencyInfo(PropagateDependencyKindToAccessors(reason.
Kind
, DependencyKind.PropertyOfPropertyMethod), method));
Linker\Annotations.cs (2)
162
Debug.Assert(!(reason.
Kind
== DependencyKind.AlreadyMarked));
176
Debug.Assert(!(reason.
Kind
== DependencyKind.AlreadyMarked));
Linker\DependencyInfo.cs (3)
158
public bool Equals(DependencyInfo other) => (
Kind
, Source) == (other.
Kind
, other.Source);
160
public override int GetHashCode() => (
Kind
, Source).GetHashCode();
Linker\DgmlDependencyRecorder.cs (2)
118
if (reason.
Kind
== DependencyKind.Unspecified)
122
RecordDependency(reason.Source, target, reason.
Kind
);
Linker\XmlDependencyRecorder.cs (1)
102
if (reason.
Kind
== DependencyKind.Unspecified)