public/swaggerui/swagger-ui.js
function parseGroupExpression() {
        var expr, expressions, startToken, i, params = [];

        expect('(');

        if (match(')')) {
            lex();
            if (!match('=>')) {
                expect('=>');
            }
            return {
                type: PlaceHolders.ArrowParameterPlaceHolder,
                params: [],
                rawParams: []
            };
        }

        startToken = lookahead;
        if (match('...')) {
            expr = parseRestElement(params);
            expect(')');
            if (!match('=>')) {
                expect('=>');
            }
            return {
                type: PlaceHolders.ArrowParameterPlaceHolder,
                params: [expr]
            };
        }

        isBindingElement = true;
        expr = inheritCoverGrammar(parseAssignmentExpression);

        if (match(',')) {
            isAssignmentTarget = false;
            expressions = [expr];

            while (startIndex < length) {
                if (!match(',')) {
                    break;
                }
                lex();

                if (match('...')) {
                    if (!isBindingElement) {
                        throwUnexpectedToken(lookahead);
                    }
                    expressions.push(parseRestElement(params));
                    expect(')');
                    if (!match('=>')) {
                        expect('=>');
                    }
                    isBindingElement = false;
                    for (i = 0; i < expressions.length; i++) {
                        reinterpretExpressionAsPattern(expressions[i]);
                    }
                    return {
                        type: PlaceHolders.ArrowParameterPlaceHolder,
                        params: expressions
                    };
                }

                expressions.push(inheritCoverGrammar(parseAssignmentExpression));
            }

            expr = new WrappingNode(startToken).finishSequenceExpression(expressions);
        }


        expect(')');

        if (match('=>')) {
            if (expr.type === Syntax.Identifier && expr.name === 'yield') {
                return {
                    type: PlaceHolders.ArrowParameterPlaceHolder,
                    params: [expr]
                };
            }

            if (!isBindingElement) {
                throwUnexpectedToken(lookahead);
            }

            if (expr.type === Syntax.SequenceExpression) {
                for (i = 0; i < expr.expressions.length; i++) {
                    reinterpretExpressionAsPattern(expr.expressions[i]);
                }
            } else {
                reinterpretExpressionAsPattern(expr);
            }

            expr = {
                type: PlaceHolders.ArrowParameterPlaceHolder,
                params: expr.type === Syntax.SequenceExpression ? expr.expressions : [expr]
            };
        }
        isBindingElement = false;
        return expr;
    }
function parseGroupExpression() {
        var expr, expressions, startToken, i, params = [];

        expect('(');

        if (match(')')) {
            lex();
            if (!match('=>')) {
                expect('=>');
            }
            return {
                type: PlaceHolders.ArrowParameterPlaceHolder,
                params: [],
                rawParams: []
            };
        }

        startToken = lookahead;
        if (match('...')) {
            expr = parseRestElement(params);
            expect(')');
            if (!match('=>')) {
                expect('=>');
            }
            return {
                type: PlaceHolders.ArrowParameterPlaceHolder,
                params: [expr]
            };
        }

        isBindingElement = true;
        expr = inheritCoverGrammar(parseAssignmentExpression);

        if (match(',')) {
            isAssignmentTarget = false;
            expressions = [expr];

            while (startIndex < length) {
                if (!match(',')) {
                    break;
                }
                lex();

                if (match('...')) {
                    if (!isBindingElement) {
                        throwUnexpectedToken(lookahead);
                    }
                    expressions.push(parseRestElement(params));
                    expect(')');
                    if (!match('=>')) {
                        expect('=>');
                    }
                    isBindingElement = false;
                    for (i = 0; i < expressions.length; i++) {
                        reinterpretExpressionAsPattern(expressions[i]);
                    }
                    return {
                        type: PlaceHolders.ArrowParameterPlaceHolder,
                        params: expressions
                    };
                }

                expressions.push(inheritCoverGrammar(parseAssignmentExpression));
            }

            expr = new WrappingNode(startToken).finishSequenceExpression(expressions);
        }


        expect(')');

        if (match('=>')) {
            if (expr.type === Syntax.Identifier && expr.name === 'yield') {
                return {
                    type: PlaceHolders.ArrowParameterPlaceHolder,
                    params: [expr]
                };
            }

            if (!isBindingElement) {
                throwUnexpectedToken(lookahead);
            }

            if (expr.type === Syntax.SequenceExpression) {
                for (i = 0; i < expr.expressions.length; i++) {
                    reinterpretExpressionAsPattern(expr.expressions[i]);
                }
            } else {
                reinterpretExpressionAsPattern(expr);
            }

            expr = {
                type: PlaceHolders.ArrowParameterPlaceHolder,
                params: expr.type === Syntax.SequenceExpression ? expr.expressions : [expr]
            };
        }
        isBindingElement = false;
        return expr;
    }
function parseGroupExpression ( ) { var expr , expressions , startToken , i , params = [ ] ; expect ( '(' ) ; if ( match ( ')' ) ) { lex ( ) ; if ( ! match ( '=>' ) ) { expect ( '=>' ) ; } return { type : PlaceHolders . ArrowParameterPlaceHolder , params : [ ] , rawParams : [ ] } ; } startToken = lookahead ; if ( match ( '...' ) ) { expr = parseRestElement ( params ) ; expect ( ')' ) ; if ( ! match ( '=>' ) ) { expect ( '=>' ) ; } return { type : PlaceHolders . ArrowParameterPlaceHolder , params : [ expr ] } ; } isBindingElement = true ; expr = inheritCoverGrammar ( parseAssignmentExpression ) ; if ( match ( ',' ) ) { isAssignmentTarget = false ; expressions = [ expr ] ; while ( startIndex < length ) { if ( ! match ( ',' ) ) { break ; } lex ( ) ; if ( match ( '...' ) ) { if ( ! isBindingElement ) { throwUnexpectedToken ( lookahead ) ; } expressions . push ( parseRestElement ( params ) ) ; expect ( ')' ) ; if ( ! match ( '=>' ) ) { expect ( '=>' ) ; } isBindingElement = false ; for ( i = 0 ; i < expressions . length ; i ++ ) { reinterpretExpressionAsPattern ( expressions [ i ] ) ; } return { type : PlaceHolders . ArrowParameterPlaceHolder , params : expressions } ; } expressions . push ( inheritCoverGrammar ( parseAssignmentExpression ) ) ; } expr = new WrappingNode ( startToken ) . finishSequenceExpression ( expressions ) ; } expect ( ')' ) ; if ( match ( '=>' ) ) { if ( expr . type === Syntax . Identifier && expr . name === 'yield' ) { return { type : PlaceHolders . ArrowParameterPlaceHolder , params : [ expr ] } ; } if ( ! isBindingElement ) { throwUnexpectedToken ( lookahead ) ; } if ( expr . type === Syntax . SequenceExpression ) { for ( i = 0 ; i < expr . expressions . length ; i ++ ) { reinterpretExpressionAsPattern ( expr . expressions [ i ] ) ; } } else { reinterpretExpressionAsPattern ( expr ) ; } expr = { type : PlaceHolders . ArrowParameterPlaceHolder , params : expr . type === Syntax . SequenceExpression ? expr . expressions : [ expr ] } ; } isBindingElement = false ; return expr ; }
ECMA-262 12.2.10 The Grouping Operator
ECMA - 262 12 . 2 . 10 The Grouping Operator