Closed asarkar closed 11 months ago
I think you've accidentally edited the file. Perhaps your IDE suggests tuple sections? The code in the exercise template doesn't use tuple sections:
@opqdonut
The code in the exercise template doesn't use tuple sections
It does.
https://github.com/moocfi/haskell-mooc/blob/ghc-9/exercises/Set13b.hs#L301
It is standard practice to wait for OP to respond to a question before closing the ticket. Please reopen.
From your original message
Set13b.hs:337:16: error: Illegal tuple section: use TupleSections
|
337 | msgSL msg = SL ((),,[msg])
| ^^^^^^^^^^^
From the source we both linked to:
msgSL msg = SL (\s -> ((),s,[msg]))
Note the difference: ((),,[msg])
vs (\s -> ((),s,[msg]))
.
Sorry about closing the ticket, I didn't realise it was important to you to keep it open. Reopened.
@opqdonut Weird, I don’t remember changing the given code. I run hlint and ormolu on the code base, and am guessing the change came from one of those. Sorry for the confusion and thank you for supporting this excellent course.
Set13b has the following:
When submitted, this fails with "Illegal tuple section" error.
The second error comes from the code I wrote, but the first error is due to OOTB code.
This can be easily fixed by adding
{-# LANGUAGE TupleSections #-}
at the top of the file, but there is a clear disconnect between the code and the assessment server.