Skip to content

Commit c6d9848

Browse files
committed
Simplify Flux catch handlers. (#421)
All `RecognitionException`s are finally caught in the `flux` catch handler which can then take the appropriate measures.
1 parent 2f73f3a commit c6d9848

File tree

1 file changed

+0
-6
lines changed
  • metafacture-flux/src/main/antlr/org/metafacture/flux/parser

1 file changed

+0
-6
lines changed

metafacture-flux/src/main/antlr/org/metafacture/flux/parser/Flux.g

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -61,9 +61,6 @@ varDef
6161
^(ASSIGN Identifier exp)
6262
;
6363
catch [RecognitionException re] {
64-
reportError(re);
65-
recover(input,re);
66-
retval.tree = (CommonTree)adaptor.errorNode(input, retval.start, input.LT(-1), re);
6764
throw re;
6865
}
6966

@@ -77,9 +74,6 @@ flow
7774
'|'! flowtail ('|'! Wormhole)? ';'!
7875
;
7976
catch [RecognitionException re] {
80-
reportError(re);
81-
recover(input,re);
82-
retval.tree = (CommonTree)adaptor.errorNode(input, retval.start, input.LT(-1), re);
8377
throw re;
8478
}
8579

0 commit comments

Comments
 (0)