Hugs | 11 Jun 14:11 2007

[Hugs] #74: Data.Word64: arithmetic overflow when evaluating maxBound + 1

#74: Data.Word64: arithmetic overflow when evaluating maxBound + 1
---------------------------------------------------+------------------------
 Reporter:  guest                                  |       Owner:  nobody
     Type:  defect                                 |      Status:  new   
 Priority:  major                                  |   Milestone:        
Component:  hugs                                   |     Version:  200609
 Keywords:  Data.Word.Word64, arithmetic overflow  |  
---------------------------------------------------+------------------------
The function (fromInteger x) in Num(Data.Word.Word64) causes a program
 error, if x is greater or equal 2^64^. This is particularly annoying when
 two valid Word64 variables are to be multiplied.

 Take for instance
 {{{
 Data.Word> maxbound :: Word64
 18446744073709551615
 Data.Word> 2*(2^63) :: Word64

 Program error: arithmetic overflow

 Data.Word> (2^64) :: Word64

 Program error: arithmetic overflow
 }}}

 GHC and GHCi return values mod 2^64^, as Hugs does also for Word32 and
 2^32^.

-- 
Ticket URL: <http://hackage.haskell.org/trac/hugs/ticket/74>
(Continue reading)

Hugs | 12 Jun 23:36 2007

[Hugs] #75: Please update FAQ to address whether a "no install" version of Hugs is available. Thx!

#75: Please update FAQ to address whether a "no install" version of Hugs is
available. Thx!
----------------------------+-----------------------------------------------
 Reporter:  guest           |       Owner:  nobody
     Type:  task            |      Status:  new   
 Priority:  minor           |   Milestone:        
Component:  hugs            |     Version:  200609
 Keywords:  faq no install  |  
----------------------------+-----------------------------------------------
Would be nice if FAQ said yes/no on this issue. Thanks much.

-- 
Ticket URL: <http://hackage.haskell.org/trac/hugs/ticket/75>
Hugs <http://www.haskell.org/hugs/>
Hugs 98, an interpreter for Haskell
_______________________________________________
Hugs-Bugs mailing list
Hugs-Bugs <at> haskell.org
http://www.haskell.org/mailman/listinfo/hugs-bugs
Hugs | 12 Jun 23:36 2007

Re: [Hugs] #75: Please update FAQ to address whether a "no install" version of Hugs is available. Thx!

#75: Please update FAQ to address whether a "no install" version of Hugs is
available. Thx!
--------------------+-------------------------------------------------------
  Reporter:  guest  |       Owner:  nobody        
      Type:  task   |      Status:  new           
  Priority:  minor  |   Milestone:                
 Component:  hugs   |     Version:  200609        
Resolution:         |    Keywords:  faq no install
--------------------+-------------------------------------------------------
-- 
Ticket URL: <http://hackage.haskell.org/trac/hugs/ticket/75>
Hugs <http://www.haskell.org/hugs/>
Hugs 98, an interpreter for Haskell
_______________________________________________
Hugs-Bugs mailing list
Hugs-Bugs <at> haskell.org
http://www.haskell.org/mailman/listinfo/hugs-bugs
Hugs | 13 Jun 01:01 2007

Re: [Hugs] #75: Please update FAQ to address whether a "no install" version of Hugs is available. Thx!

#75: Please update FAQ to address whether a "no install" version of Hugs is
available. Thx!
--------------------------+-------------------------------------------------
  Reporter:  guest        |       Owner:  nobody        
      Type:  enhancement  |      Status:  new           
  Priority:  minor        |   Milestone:                
 Component:  hugs         |     Version:  200609        
Resolution:               |    Keywords:  faq no install
--------------------------+-------------------------------------------------
Changes (by ross):

  * type:  task => enhancement

Comment:

 I don't understand the question.  Please expand.

-- 
Ticket URL: <http://hackage.haskell.org/trac/hugs/ticket/75>
Hugs <http://www.haskell.org/hugs/>
Hugs 98, an interpreter for Haskell
_______________________________________________
Hugs-Bugs mailing list
Hugs-Bugs <at> haskell.org
http://www.haskell.org/mailman/listinfo/hugs-bugs
Hugs | 13 Jun 01:09 2007

Re: [Hugs] #75: Please update FAQ to address whether a "no install" version of Hugs is available. Thx!

#75: Please update FAQ to address whether a "no install" version of Hugs is
available. Thx!
--------------------------+-------------------------------------------------
  Reporter:  guest        |       Owner:  nobody        
      Type:  enhancement  |      Status:  new           
  Priority:  minor        |   Milestone:                
 Component:  hugs         |     Version:  200609        
Resolution:               |    Keywords:  faq no install
--------------------------+-------------------------------------------------
Comment (by neil):

 In particular, is this a Windows or a Linux question?

-- 
Ticket URL: <http://hackage.haskell.org/trac/hugs/ticket/75>
Hugs <http://www.haskell.org/hugs/>
Hugs 98, an interpreter for Haskell
_______________________________________________
Hugs-Bugs mailing list
Hugs-Bugs <at> haskell.org
http://www.haskell.org/mailman/listinfo/hugs-bugs
Ian Lynagh | 13 Jun 02:34 2007
Picon

Re: [Hugs] #75: Please update FAQ to address whether a "no install" version of Hugs is available. Thx!

On Tue, Jun 12, 2007 at 11:01:10PM -0000, Hugs wrote:
> #75: Please update FAQ to address whether a "no install" version of Hugs is
> available. Thx!
> 
>  I don't understand the question.  Please expand.

I think he wants a hugs binary tarball/zip that you can just untar/unzip
and use in-place.

Thanks
Ian
Fatih Aşıcı | 17 Jun 18:48 2007
Picon

Build system corrupts LDFLAGS options

Hi,

I am trying to compile hugs98 with

LDFLAGS="-Wl,-Bdirect -Wl,-hashvals -Wl,-zdynsort"

While compiling OpenGL stuff, somehow it changes LDFLAGS to

-Wl -Bdirect -hashvals -zdynsort

and causes the build process to fail with the following messages:

i686-pc-linux-gnu-gcc: unrecognized option `-hashvals'
i686-pc-linux-gnu-gcc: unrecognized option `-zdynsort'
cc1: error: unrecognized command line option "-Wl"
runhugs: Error occurred

How can I build hugs98 with these flags?

Thanks,
Fatih
Neil Mitchell | 26 Jun 03:09 2007
Picon

Stack overflow on words (repeat 'a')

Hi

With the expression: words (repeat 'a')

Using WinHugs Sep 06 I get a stack overflow.

Using Hugs Linux May 06 I get a GC fails to reclaim sufficient space error

Using GHC and Yhc both of these succeed.

I have a similar issue in one of my functions which is showing the
same behaviour.

Thanks

Neil
Claus Reinke | 26 Jun 12:47 2007

Re: Stack overflow on words (repeat 'a')

> With the expression: words (repeat 'a')
> 
> Using WinHugs Sep 06 I get a stack overflow.
> 
> Using Hugs Linux May 06 I get a GC fails to reclaim sufficient space error
> 
> Using GHC and Yhc both of these succeed.
> 
> I have a similar issue in one of my functions which is showing the
> same behaviour.

assuming you've got a terminating application in mind,-) a slightly 
more interesting expression is:

    test span = span (/=' ') $ replicate 100000 'a' ++ [' ']

without optimizations, hugs is prone to fail for such deep applications
of non-tail-recursive functions like span/break, splitAt, ..

try this variation:

span p l = span' p l id
  where
  span' p []     = \c->c ([],[])
  span' p xs <at> (x:xs') 
     | p x       = span' p xs' . (\c (a,b)->c (x:a,b))
     | otherwise = \c->c ([],xs)

claus
(Continue reading)

Claus Reinke | 26 Jun 13:26 2007

Re: Stack overflow on words (repeat 'a')

i should have mentioned that Prelude.span is less strict, so:

span p l = span' p l id
  where
  span' p []     = \c->c ([],[])
  span' p xs <at> (x:xs') 
     | p x       = span' p xs' . (\c (a,b)->c (x:a,b))
     | otherwise = \c->c ([],xs)

-- Prelude.span fails, span succeeds
test1 span = span (/=' ') $ replicate 1000000 'a' ++ [' ']
test2 span = span (/=' ') $ take 1000000 (cycle "abc") ++ [' ']

-- Prelude.span succeeds, span fails
test3 span = take 1000000 $ fst $ span (/=' ') $ repeat 'a'

claus

Gmane