[clean-list] Grammar definition inconsistent in language
report
John van Groningen
johnvg at cs.ru.nl
Wed Nov 29 17:46:25 MET 2006
Jigang Sun wrote:
>Could anyone check Clean 2.1 grammar in language report?
>
>Function typing on page 26, right side if -> is type
>
>FunctionType = Type -> Type [ClassContext] [UnqTypeUnEqualities]
>
>but on page 112, Type_Expression other than Type
>FunctionType = [Type -> ] Type_Expression [ClassContext] [UnqTypeUnEqualities]
>
>Could right side of arrow be BrackType ?
I think this should be:
FunctionType = [Type -> ] Type [ClassContext] [UnqTypeUnEqualities]
>class type definition on page 58, one multiple occurences of TypeVariable:
>
>TypeClassDef = class ClassName TypeVariable+ [ClassContext]
>[[where] { {ClassMemberDef}+ }]
>| class FunctionName TypeVariable+ :: FunctionType;
>| class (FunctionName) [Fix][Prec] TypeVariable+ :: FunctionType;
>
>on page 116, one occurence of TypeVariable
>
>TypeClassDef = class ClassName TypeVariable [ClassContext]
>[[where] { {ClassMemberDef}+ }]
>| class FunctionName TypeVariable :: FunctionType;
>| class (FunctionName) [Fix][Prec] TypeVariable :: FunctionType;
The first one is correct.
Kind regards,
John van Groningen
More information about the clean-list
mailing list