Version française
Home     About     Download     Resources     Contact us    
Browse thread
[Caml-list] unused variables warning
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Sven LUTHER <luther@d...>
Subject: Re: [Caml-list] unused variables warning
On Sun, Apr 29, 2001 at 11:58:22AM +0200, Pixel wrote:
> Vitaly Lugovsky <vsl@ontil.ihep.su> writes:
> 
> [...]
> 
> > > let f x =
> > >    let x' = <...> in
> > >    x
> > >
> > > would issue something like
> > >
> > > File "test.ml", line 2, characters 3-18:
> > > Unused variable x'
> > 
> >  It's "unused" and can be optimized out only when <...> is a pure
> > functional statement (not changing global state). 
> 
> even if the <...> is unpure, caml could warn that x' is unused. It doesn't mean
> in any way that computing x' is unnecessary.
> 
> and caml should not warn for
> 
> let _x' = <...> in

I guess you mean just :

let _ = <...> in 

?

Friendly,

Sven Luther
-------------------
To unsubscribe, mail caml-list-request@inria.fr.  Archives: http://caml.inria.fr