-
Notifications
You must be signed in to change notification settings - Fork 170
Closed
Description
LBNF file:
P. Decl ::= "private" "{" [Decl] "}" ;
separator Decl ";" ;
layout "private" ;
Input:
private
private
private {} -- should work
This is reconstructed as
private {
; private {}
private {} -- missing semicolon
}
The problem is that the following code does not check whether a layoutSep
needs to be inserted:
bnfc/source/src/BNFC/Backend/Haskell/CFtoLayout.hs
Lines 103 to 105 in e34f1b8
, " -- Explicit layout, just move on. The case above" | |
, " -- will push an explicit layout block." | |
, " t1 : _ | isLayoutOpen t1 -> t0 : res (Just t0) st ts" |