> f,g :: Bool -> Int > f x = 6 > g x = 6 > > We can in Haskell compute that these two functions are equal, without solving > the halting problem.
what about these? f,g :: Bool -> Int f x = 6 g x = x `seq` 6 /Jonas 2010/4/14 Thomas Davie <tom.da...@gmail.com>: > > On 14 Apr 2010, at 09:01, Jonas Almström Duregård wrote: > >>> But if one did start considering bottom to be a value, one would have to >>> distinguish different ones. For instance, (error "ABC") vs. (error >>> "PQR"). Obviously this is not finite. >> >> Nor is it computable, since it must distinguish terminating programs >> from nonterminating ones (i.e. the halting problem). >> >> On a side note, since "instance (Finite a, Finite b) => Finite (a -> >> b)" should be possible, one can even compare some higher order >> functions with this approach ;). > > f,g :: Bool -> Int > f x = 6 > g x = 6 > > We can in Haskell compute that these two functions are equal, without solving > the halting problem. > > Bob _______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe