Could someone help me fix the code below in cgywin64 to correct the errors in bold at the bottom Below is the description of the question, followed by the codes, and the errors in bold. Thank you so much for the help. Please modify the given code instead of making a new one.Description:The question involves modifying the syntactic analyzer for the attached compiler by adding to the existing grammar. The full grammar of the language is shown below. The highlighted portions of the grammar show what you must either modify or add to the existing grammar.function: function_header {variable} body function_header: FUNCTION IDENTIFIER [parameters] RETURNS type ; variable: IDENTIFIER : type IS statement parameters: parameter {, parameter} parameter: IDENTIFIER : type type: INTEGER | REAL | BOOLEAN body: BEGIN statement END ; statement: expression ; | REDUCE operator {statement} ENDREDUCE ; | IF expression THEN statement ELSE statement ENDIF ; | CASE expression IS {case} OTHERS ARROW statement ENDCASE ; operator: ADDOP | MULOP case: WHEN INT_LITERAL ARROW statement expression: ( expression ) | expression binary_operator expression | NOTOP expression | INT_LITERAL | REAL_LITERAL | BOOL_LITERAL | IDENTIFIER binary_operator: ADDOP | MULOP | REMOP | EXPOP | RELOP | ANDOP |OROPIn the above grammar, the red symbols are nonterminals, the blue symbols are terminals and the black punctuation are EBNF metasymbols. The braces denote repetition 0 or more times and the brackets denote optional. You must rewrite the grammar to eliminate the EBNF brace and bracket metasymbols and to incorporate the significance of parentheses, operator precedence and associativity for all operators. Among arithmetic operators the exponentiation operator has highest precedence following by the multiplying operators and then the adding operators. All relational operators have the same precedence. Among the binary logical operators, and has higher precedence than or. Of the categories of operators, the unary logical operator has highest precedence, the arithmetic operators have next highest precedence, followed by the relational operators and finally the binary logical operators. All operators except the exponentiation operator are left associative. The directives to specify precedence and associativity, such as %prec and %left, may not be used Your parser should be able to correctly parse any syntactically correct program without any problem. You must modify the syntactic analyzer to detect and recover from additional syntax errors using the semicolon as the synchronization token. To accomplish detecting additional errors an error production must be added to the function header, another to the variable declaration and a final one to the when clause of the case statement. Your bison input file should not produce any shift/reduce or reduce/reduce errors. Eliminating them can be difficult so the best strategy is not introduce any. That is best achieved by making small incremental additions to the grammar and ensuring that no addition introduces any such errors. An example of compilation listing output containing syntax errors is shown below: 1 -- Multiple errors 2 3 function main a integer returns real; Syntax Error, Unexpected INTEGER, expecting ':' 4 b: integer is * 2; Syntax Error, Unexpected MULOP 5 c: real is 6.0; 6 begin 7 if a > c then 8 b 3.0; Syntax Error, Unexpected REAL_LITERAL, expecting ';' 9 else 10 b = 4.; 11 endif; 12 ; Syntax Error, Unexpected ';', expecting END Lexical Errors 0 Syntax Errors 4 Semantic Errors 0 listing.cc:// This file contains the bodies of the functions that produces the compilation// listing#include <cstdio>#include <string>using namespace std;#include "listing.h"static int lineNumber;static string error = "";static int totalErrors = 0;static void displayErrors();void firstLine(){lineNumber = 1;printf("\n%4d ",lineNumber);}void nextLine(){displayErrors();lineNumber++;printf("%4d ",lineNumber);}int lastLine(){printf("\r");displayErrors();printf(" \n");return totalErrors;} void appendError(ErrorCategories errorCategory, string message){string messages[] = { "Lexical Error, Invalid Character ", "", "Semantic Error, ", "Semantic Error, Duplicate Identifier: ", "Semantic Error, Undeclared " };error = messages[errorCategory] + message;totalErrors++;}void displayErrors(){if (error != "") printf("%s\n", error.c_str());error = "";}listing.h:// This file contains the function prototypes for the functions that produce the // compilation listingenum ErrorCategories {LEXICAL, SYNTAX, GENERAL_SEMANTIC, DUPLICATE_IDENTIFIER,UNDECLARED};void firstLine();void nextLine();int lastLine();void appendError(ErrorCategories errorCategory, string message);makefile:compile: scanner.o parser.o listing.og++ -o compile scanner.o parser.o listing.oscanner.o: scanner.c listing.h tokens.hg++ -c scanner.cscanner.c: scanner.lflex scanner.lmv lex.yy.c scanner.cparser.o: parser.c listing.h g++ -c parser.cparser.c tokens.h: parser.ybison -d -v parser.ymv parser.tab.c parser.ccp parser.tab.h tokens.hlisting.o: listing.cc listing.hg++ -c listing.ccparser.y:%{#include <string>using namespace std;#include "listing.h"int yylex();void yyerror(const char* message);%}%define parse.error verbose%token IDENTIFIER%token INT_LITERAL%token REAL_LITERAL%token BOOL_LITERAL%token ADDOP MULOP RELOP OROP ANDOP EXPOP REMOP%token BEGIN_ BOOLEAN END ENDREDUCE FUNCTION INTEGER IS REDUCE RETURNS CASE ELSE ARROW%token ENDCASE ENDIF IF OTHERS REAL THEN WHEN NOT%%function:function_header different_parameter body ;function_header:FUNCTION IDENTIFIER diff_parameter RETURNS type ';' ;different_parameter:different_parameter variable |;variable:IDENTIFIER ':' type IS statement_ ;diff_parameter:diff_parameter RETURNS type ',' |parameter ;parameter:IDENTIFIER ':' type |;type: INTEGER | REAL | BOOLEAN ;body:BEGIN_ statement_ END ';' ;statement_:statement ';' |error ';' ;statement:expression |REDUCE operator reductions ENDREDUCE |IF expression THEN statement_ ELSE statement_ ENDIF |CASE expression IS various_cases OTHERS ARROW statement_ ENDCASE ;reductions:reductions statement_ |;various_cases:various_cases case |;case: WHEN INT_LITERAL ARROW statement_ ;operator:ADDOP |MULOP | REMOP |EXPOP ;expression:expression ANDOP relation |expression2;expression2:expression OROP relation |relation;relation:relation RELOP term |term;term:term ADDOP factor |factor ;factor:factor MULOP primary |factor REMOP |exponent ;exponent:factor EXPOP notion |notion;notion:notion NOT primary |primary;primary:'(' expression ')' |INT_LITERAL | REAL_LITERAL | BOOL_LITERAL |IDENTIFIER ;%%void yyerror(const char* message){appendError(SYNTAX, message);}int main(int argc, char *argv[]){firstLine();yyparse();lastLine();return 0;}scanner.l:/* This file contains flex input file */%{#include <cstdio>#include <string>using namespace std;#include "listing.h"#include "tokens.h"%}%option noyywrapws [ \t\r]+comment ("//"|"--").*\nid [A-Za-z](_?[A-Za-z0-9])*real {digit}+\.{digit}*([Ee][+-]?{digit}+)?line [\n]digit [0-9]int {digit}+punc [\(\),:;]%%{ws} { ECHO; }{comment} { ECHO; nextLine();}{line} { ECHO; nextLine();}"+" { ECHO; return(ADDOP); }"*" { ECHO; return(MULOP); }"=>" { ECHO; return(ARROW); }"<" { ECHO; return(RELOP); }"=" { ECHO; return(RELOP); }"/=" { ECHO; return(RELOP); }">" { ECHO; return(RELOP); }">=" { ECHO; return(RELOP); }"<=" { ECHO; return(RELOP); }"-" { ECHO; return(ADDOP); }"/" { ECHO; return(MULOP); }"**" { ECHO; return(EXPOP); }"." { ECHO; return(MULOP); }rem { ECHO; return(REMOP); }or { ECHO; return(OROP); }not { ECHO; return(NOTOP); }case { ECHO; return(CASE); }else { ECHO; return(ELSE); }endcase { ECHO; return(ENDCASE); }others { ECHO; return(OTHERS); }endif { ECHO; return(ENDIF); }if { ECHO; return(IF); }real { ECHO; return(REAL); }then { ECHO; return(THEN); }when { ECHO; return(WHEN); }begin { ECHO; return(BEGIN_); }boolean { ECHO; return(BOOLEAN); }end { ECHO; return(END); }endreduce { ECHO; return(ENDREDUCE); }function { ECHO; return(FUNCTION); }integer { ECHO; return(INTEGER); }is { ECHO; return(IS); }reduce { ECHO; return (REDUCE); }returns { ECHO; return(RETURNS); }and { ECHO; return(ANDOP); }true { ECHO; return(BOOL_LITERAL); }false { ECHO; return(BOOL_LITERAL); }{id} { ECHO; return(IDENTIFIER);}{real} {ECHO; return(REAL_LITERAL);}{int} { ECHO; return(INT_LITERAL); }{punc} { ECHO; return(yytext[0]); }. { ECHO; appendError(LEXICAL, yytext); }%%tokens.h:/* A Bison parser, made by GNU Bison 3.8.2. *//* Bison interface for Yacc-like parsers in C Copyright (C) 1984, 1989-1990, 2000-2015, 2018-2021 Free Software Foundation, Inc. This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . *//* As a special exception, you may make a larger work that contains part or all of the Bison parser skeleton and distribute that work under terms of your choice, so long as that work isn't itself a parser generator using the skeleton or a modified version thereof as a parser skeleton. Alternatively, if you modify or redistribute the parser skeleton itself, you may (at your option) remove this special exception, which will cause the skeleton and the resulting Bison output files to be licensed under the GNU General Public License without this special exception. This special exception was added by the Free Software Foundation in version 2.2 of Bison. *//* DO NOT RELY ON FEATURES THAT ARE NOT DOCUMENTED in the manual, especially those whose name start with YY_ or yy_. They are private implementation details that can be changed or removed. */#ifndef YY_YY_PARSER_TAB_H_INCLUDED# define YY_YY_PARSER_TAB_H_INCLUDED/* Debug traces. */#ifndef YYDEBUG# define YYDEBUG 0#endif#if YYDEBUGextern int yydebug;#endif/* Token kinds. */#ifndef YYTOKENTYPE# define YYTOKENTYPE enum yytokentype { YYEMPTY = -2, YYEOF = 0, /* "end of file" */ YYerror = 256, /* error */ YYUNDEF = 257, /* "invalid token" */ IDENTIFIER = 258, /* IDENTIFIER */ INT_LITERAL = 259, /* INT_LITERAL */ REAL_LITERAL = 260, /* REAL_LITERAL */ BOOL_LITERAL = 261, /* BOOL_LITERAL */ ADDOP = 262, /* ADDOP */ MULOP = 263, /* MULOP */ RELOP = 264, /* RELOP */ OROP = 265, /* OROP */ ANDOP = 266, /* ANDOP */ EXPOP = 267, /* EXPOP */ REMOP = 268, /* REMOP */ BEGIN_ = 269, /* BEGIN_ */ BOOLEAN = 270, /* BOOLEAN */ END = 271, /* END */ ENDREDUCE = 272, /* ENDREDUCE */ FUNCTION = 273, /* FUNCTION */ INTEGER = 274, /* INTEGER */ IS = 275, /* IS */ REDUCE = 276, /* REDUCE */ RETURNS = 277, /* RETURNS */ CASE = 278, /* CASE */ ELSE = 279, /* ELSE */ ARROW = 280, /* ARROW */ ENDCASE = 281, /* ENDCASE */ ENDIF = 282, /* ENDIF */ IF = 283, /* IF */ OTHERS = 284, /* OTHERS */ REAL = 285, /* REAL */ THEN = 286, /* THEN */ WHEN = 287, /* WHEN */ NOT = 288, /* NOT */ NOTOP = 289 }; typedef enum yytokentype yytoken_kind_t;#endif/* Value type. */#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLAREDtypedef int YYSTYPE;# define YYSTYPE_IS_TRIVIAL 1# define YYSTYPE_IS_DECLARED 1#endifextern YYSTYPE yylval;int yyparse (void);#endif /* !YY_YY_PARSER_TAB_H_INCLUDED */ This production is not correct:function: function_header different_parameter body ;What is the diferent_parameter there for? Parameters are inside the function header not after it.Also this one does not look right:diff_parameter:diff_parameter RETURNS type ',' |parameter ;Professors notes: The RETURNS is already in function header. It should not be part of the parameter production.What you need is something like this:function_header: FUNCTION IDENTIFIER optional_parameters RETURNS type ;Then you need a production for optional_parameters that has two RHSs. One is empty, the other another nonterminal, call it parameters, for example.Then the parameters production must have a recursive RHS that separates parameters by a comma and a non-recursive RHS that defines a single parameter.The only other thing is see that obviously looks wrong is you production for not. Not is a unary operator. It should only have one operand.I have attached the Project Requirements, the Project Approach and the test cases. Please make sure that all the test cases work and match the Project Approach.