thanks!
case timeout of
Just str ->
case reads str of
[(t,_)] -> addtimeout (hPutStrLn stderr "*** TIMEOUT" >> _exit 1)
_ -> return ()
_ -> return ()
is VERY clear!
Daniel Fischer-4 wrote:
>
> Am Sonntag 28 Februar 2010 02:08:18 schrieb zaxis:
>> Then can i change it to
On Sat, Feb 27, 2010 at 05:08:18PM -0800, zaxis wrote:
> Then can i change it to :
> case timeout of
> Just str -> do
> [(t, _)] <- reads str
> addTimeout t (hPutStrLn stderr "*** TIMEOUT" >> _exit 1)
> return ()
> _ -> return ()
No, that's diffe
Am Sonntag 28 Februar 2010 02:08:18 schrieb zaxis:
> Then can i change it to :
> case timeout of
> Just str -> do
> [(t, _)] <- reads str
> addTimeout t (hPutStrLn stderr "*** TIMEOUT" >> _exit 1)
> return ()
> _ -> return ()
>
> Sincerely!
No. T
Then can i change it to :
case timeout of
Just str -> do
[(t, _)] <- reads str
addTimeout t (hPutStrLn stderr "*** TIMEOUT" >> _exit 1)
return ()
_ -> return ()
Sincerely!
Brandon S. Allbery KF8NH wrote:
>
> On Feb 27, 2010, at 04:07 , zaxis
On Sat, Feb 27, 2010 at 9:29 AM, Brandon S. Allbery KF8NH
wrote:
> On Feb 27, 2010, at 04:07 , zaxis wrote:
>>
>> xxxMain = do
>> timeout <- getEnv "xxx_TIMEOUT"
>> case timeout of
>> Just str | [(t, _)] <- reads str -> do
>> addTimeout t (hPutStrLn stderr "*** TIMEOUT" >> _exi
On Feb 27, 2010, at 04:07 , zaxis wrote:
xxxMain = do
timeout <- getEnv "xxx_TIMEOUT"
case timeout of
Just str | [(t, _)] <- reads str -> do
addTimeout t (hPutStrLn stderr "*** TIMEOUT" >> _exit 1)
return ()
_ -> return ()
...
What does the `|` mean
On Sat, Feb 27, 2010 at 5:07 PM, zaxis wrote:
>
> xxxMain = do
> timeout <- getEnv "xxx_TIMEOUT"
> case timeout of
> Just str | [(t, _)] <- reads str -> do
> addTimeout t (hPutStrLn stderr "*** TIMEOUT" >> _exit 1)
> return ()
> _ -> return ()
> ...
>
xxxMain = do
timeout <- getEnv "xxx_TIMEOUT"
case timeout of
Just str | [(t, _)] <- reads str -> do
addTimeout t (hPutStrLn stderr "*** TIMEOUT" >> _exit 1)
return ()
_ -> return ()
...
What does the `|` mean in "Just str | [(t, _)] <- reads str