An obscure corner of the Haskell Report
Section 5.2 of the Haskell 2010 Report deals with module export lists. At one point, it says:
Entities in an export list may be named as follows:
...
But, uh... am I missing something? Because according to the Syntax Reference in Chapter 10:
qvarid → [ monid . ] varid
varid → ( small { small | large | digit | ' })
So in which universe does putting an operator in brackets turn it into a qvarid? It looks to me like an operator is clearly a varsym (or maybe qvarsym).
Does anybody know what's going on here? I mean, clearly Haskell definitely supports writing operators in an export list, but the syntax description in the Report doesn't appear to make sense...
Wait, hold up... According to the Control-Free Syntax given in section 10.5:
export → qvar | qtycon ... | qtycls ... | module
monid
...
var → varid | (
varsym )
qvar → qvarid | (
qvarsym )
So it seems that it's not a qvarid, it's supposed to be a qvar. So it's just a typo, I guess? Is there a process for having such things fixed in the official report?
链接地址: http://www.djcxy.com/p/87452.html下一篇: 哈斯克尔报告中一个不起眼的角落