Пример #1
0
        void ITreeWalker.Visit(InterpolatedExpression expression)
        {
            var replacements = expression.Replacements;

            expression.Validate(this);
            InsertInterpolatedString(expression.Format.Value as String, replacements.Length, i => replacements[i].Accept(this));
        }
        void ITreeWalker.Visit(InterpolatedExpression expression)
        {
            expression.Validate(this);
            expression.Format.Accept(this);

            foreach (var replacement in expression.Replacements)
            {
                replacement.Accept(this);
            }
        }
Пример #3
0
        void ITreeWalker.Visit(InterpolatedExpression expression)
        {
            var length = expression.Replacements.Length + 1;

            expression.Validate(this);

            foreach (var replacement in expression.Replacements)
            {
                replacement.Accept(this);
            }

            expression.Format.Accept(this);
            CallFunction(StandardFunctions.Format, length);
        }
Пример #4
0
        void ITreeWalker.Visit(InterpolatedExpression expression)
        {
            var replacements = expression.Replacements;
            var length       = replacements.Length + 1;

            expression.Validate(this);

            for (var i = replacements.Length - 1; i >= 0; i--)
            {
                replacements[i].Accept(this);
            }

            expression.Format.Accept(this);
            CallFunction(StandardFunctions.Format, length);
        }