/// <summary>
        /// Creates a new expression that is like this one, but using the supplied children. If all of the children are the same, it will return this expression.
        /// </summary>
        /// <param name="variables">The <see cref="Variables" /> property of the result.</param>
        /// <param name="pattern">The <see cref="Pattern" /> property of the result.</param>
        /// <param name="whenClause">The <see cref="WhenClause" /> property of the result.</param>
        /// <param name="value">The <see cref="Value" /> property of the result.</param>
        /// <returns>This expression if no children changed, or an expression with the updated children.</returns>
        public SwitchExpressionArm Update(IEnumerable <ParameterExpression> variables, CSharpPattern pattern, Expression whenClause, Expression value)
        {
            if (SameElements(ref variables, Variables) && pattern == Pattern && whenClause == WhenClause && value == Value)
            {
                return(this);
            }

            return(CSharpExpression.SwitchExpressionArm(variables, pattern, whenClause, value));
        }