public static bool HasHotIcon(this IDeclaredElement element, PerformanceCriticalContextProvider contextProvider, IContextBoundSettingsStore settingsStore, IReadOnlyCallGraphContext context) { if (element == null) { return(false); } if (!settingsStore.GetValue((UnitySettings key) => key.EnableIconsForPerformanceCriticalCode)) { return(false); } return(contextProvider.IsMarkedStage(element, context)); }
protected override bool CheckCallGraph(IMethodDeclaration methodDeclaration, IReadOnlyCallGraphContext context) { var declaredElement = methodDeclaration.DeclaredElement; return(myPerformanceCriticalContextProvider.IsMarkedStage(declaredElement, context)); }