[Solved]2 Assume Add New Kind Conditional Statement C Java Signtest Structure Signtest Exp Neg Stm Q37212894

2. Assume that we add a new kind of conditional statement to C or Java, the signtest. Its structure is: signtest exp neg: stmts zero: stmts pos: stmts The integer expression exp is evaluated. If it is negative, the statements following neg are executed. If it is zero, the statements following zero are executed. If it is positive, the statements following pos are executed. Show the AST you would use for this construct. Revise the semantic analysis, reachability, and throws visitors for if statements (Section 9.1.2) lo handk: th: sini Show transcribed image text 2. Assume that we add a new kind of conditional statement to C or Java, the signtest. Its structure is: signtest exp neg: stmts zero: stmts pos: stmts The integer expression exp is evaluated. If it is negative, the statements following neg are executed. If it is zero, the statements following zero are executed. If it is positive, the statements following pos are executed. Show the AST you would use for this construct. Revise the semantic analysis, reachability, and throws visitors for if statements (Section 9.1.2) lo handk: th: sini
Expert Answer
Answer to 2. Assume that we add a new kind of conditional statement to C or Java, the signtest. Its structure is: signtest exp neg… . . .
OR

