private static VariableSource CreateVariableSourceForArgument( TypedVarDefSyntaxNode argSyntax, FunnyType actualType) { if (argSyntax.FunnyType != FunnyType.Empty) { return(VariableSource.CreateWithStrictTypeLabel( name: argSyntax.Id, type: actualType, typeSpecificationIntervalOrNull: argSyntax.Interval, isOutput: false)); } else { return(VariableSource.CreateWithoutStrictTypeLabel( name: argSyntax.Id, type: actualType, isOutput: false)); } }
public IExpressionNode Visit(TypedVarDefSyntaxNode node) => ThrowNotAnExpression(node);
public static Exception AnonymousFunctionArgumentDuplicates(TypedVarDefSyntaxNode argNode, ISyntaxNode funDefinition) => new FunParseException(563, $"'Argument '{argNode.Id}:{argNode.FunnyType}' of anonymous fun duplicates ", argNode.Interval);
public static Exception FunctionArgumentDuplicates(UserFunctionDefinitionSyntaxNode lexFunction, TypedVarDefSyntaxNode lexFunctionArg) => new FunParseException(554, $"'Argument name '{lexFunctionArg.Id}' duplicates at {ErrorsHelper.Signature(lexFunction.Id, lexFunction.Args)} ", lexFunction.Head.Interval);
public virtual VisitorEnterResult Visit(TypedVarDefSyntaxNode node) => DefaultVisitEnter(node);
public string Visit(TypedVarDefSyntaxNode node) => $"'{node.Id}:{node.FunnyType}";
public virtual bool Visit(TypedVarDefSyntaxNode node) => true;