Implement "Meaningful main return types" proposal
The GHC Steering Committee has accepted the proposal "Meaningful main return types", which introduces:
- a new extension
MeaningfulMainReturn
under whichmain
is required to have a typeIO ()
,IO Void
orIO ExitCode
, with the latter arranging to return theExitCode
on program termination; and - a new on-by-default warning
-Wambiguous-main-return
which will complain ifmain
has a type other thanIO ()
orIO Void
(andMeaningfulMainReturn
is not in effect).