protected override IEnumerable <Warning> Warnings()
        {
            foreach (var baseWarning in base.Warnings())
            {
                yield return(baseWarning);
            }

            if (unit.graph != null)
            {
                foreach (var definitionWarning in UnitPortDefinitionUtility.Warnings(unit.graph, LinqUtility.Concat <IUnitPortDefinition>(unit.graph.controlInputDefinitions, unit.graph.valueInputDefinitions)))
                {
                    yield return(definitionWarning);
                }

                var inputs = unit.graph.units.Where(u => u is GraphInput).ToList();
                if (inputs.Count > 1)
                {
                    var firstInput = inputs[0];
                    if (unit != firstInput)
                    {
                        var graphName = string.IsNullOrEmpty(unit.graph.title) ? nameof(SubgraphUnit) : unit.graph.title;
                        Debug.LogWarning($"Only one Input node can be used and will execute in {graphName}.");
                        yield return(Warning.Caution("Only one Input node can be used and will execute."));
                    }
                }
            }
        }
        protected override IEnumerable <Warning> Warnings()
        {
            foreach (var baseWarning in base.Warnings())
            {
                yield return(baseWarning);
            }

            if (unit.graph != null)
            {
                foreach (var definitionWarning in UnitPortDefinitionUtility.Warnings(unit.graph, LinqUtility.Concat <IUnitPortDefinition>(unit.graph.controlInputDefinitions, unit.graph.valueInputDefinitions)))
                {
                    yield return(definitionWarning);
                }
            }
        }
        protected override IEnumerable <Warning> Warnings()
        {
            foreach (var baseWarning in base.Warnings())
            {
                yield return(baseWarning);
            }

            if (unit.graph != null)
            {
                foreach (var definitionWarning in UnitPortDefinitionUtility.Warnings(unit.graph, LinqUtility.Concat <IUnitPortDefinition>(unit.graph.controlOutputDefinitions, unit.graph.valueOutputDefinitions)))
                {
                    yield return(definitionWarning);
                }

                if (unit.graph.units.Count(unit => unit is GraphOutput) > 1)
                {
                    yield return(Warning.Caution("Multiple output nodes in the same graph. Only one of them will be used."));
                }
            }
        }