From e70246a799b0038cf84874550283c52858231159 Mon Sep 17 00:00:00 2001 From: Simon Marlow Date: Mon, 21 Aug 2006 09:59:12 +0000 Subject: [PATCH] comply with Haskell 98 by not allowing extra commas in import/export lists --- compiler/parser/Parser.y.pp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/compiler/parser/Parser.y.pp b/compiler/parser/Parser.y.pp index 3bb5ab4..1469a66 100644 --- a/compiler/parser/Parser.y.pp +++ b/compiler/parser/Parser.y.pp @@ -343,9 +343,8 @@ maybeexports :: { Maybe [LIE RdrName] } | {- empty -} { Nothing } exportlist :: { [LIE RdrName] } - : exportlist ',' export { $3 : $1 } - | exportlist ',' { $1 } - | export { [$1] } + : export { [$1] } + | export ',' exportlist { $1 : $3 } | {- empty -} { [] } -- No longer allow things like [] and (,,,) to be exported -- 1.7.10.4