[Haskell-beginners] Questions on GHCi 6.10.4 + general questions

Lev Broido lev.broido at gmail.com
Fri Nov 27 04:52:07 EST 2009


On Fri, Nov 27, 2009 at 11:48 AM, Lev Broido <lev.broido at gmail.com> wrote:

> Thanks for reply .
> I used braces , since previous error was on indentation and I wasn't sure
> what was wrong .
> The intent of the  *curr_bank_state =  head . filter (\y -> y ==
> (wr_bank,_) state was
> *get first entry (only entry) from list of tuples (Time,BankStateSIngle)
> matching condition Time == wr_bank .
>
> After removing braces the message is
>   DdrController.hs:112:8:
>     parse error (possibly incorrect indentation)
> Failed, modules loaded: none.
>
> Thanks,
> Lev
>
>
> On Fri, Nov 27, 2009 at 11:15 AM, Stephen Tetley <stephen.tetley at gmail.com
> > wrote:
>
>> Hi Lev
>>
>> Where clauses don't use braces so that's first problem.
>>
>> Also this line near the end has a problem:
>>
>>          curr_bank_state =  head . filter (\y -> y == (wr_bank,_) state
>>
>> What should it be doing?
>>
>> Best wishes
>>
>> Stephen
>>
>> 2009/11/27 Lev Broido <lev.broido at gmail.com>:
>> > Hi
>> > I am getting the following message :
>> > parse error on input `=
>> > Code in question is attached .
>> >
>> > Another general question on haskell :
>> > I am not sure I understand correctly  the 'where' clause usage , I'll
>> > happily accept comments on the code
>> >
>> > Thanks,
>> > Lev
>> >
>> >
>> > _______________________________________________
>> > Beginners mailing list
>> > Beginners at haskell.org
>> > http://www.haskell.org/mailman/listinfo/beginners
>> >
>> >
>>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.haskell.org/pipermail/beginners/attachments/20091127/217d4493/attachment.html


More information about the Beginners mailing list