Compiler versions

Jon Cast jcast at ou.edu
Wed Apr 7 15:54:29 EDT 2004


Malcolm Wallace <Malcolm.Wallace at cs.york.ac.uk> wrote:

<snip>

> I remember Mark Jones suggesting more-or-less exactly this idea back
> in about 1998/1999.  It has been implemented in nhc98 ever since, but
> I finally deleted it from CVS recently because no other systems
> supported it.  And (probably the more major reason) because I
> frequently forgot to keep it up to date.  Here was the signature:
> 
>     module Haskell where
>  
>     import Time
>     import Locale
>  
>     systemName     :: String        -- "Hugs", "GHC", "hbc", "nhc", "qhc", ..
> .
>     haskellVersion :: Int           -- 13, 14, 98, 2000, ...
      ^^^^^^^^^^^^^^^^^^^^^

I wholeheartedly endorse this, but these days I think (Version,
[String]) would be a better type, i.e., (haskell98, ["Standard FFI",
"Multi-parameter type classes", "Functional Dependencies", ...].
Knowing the Haskell version number by itself won't be much good until
the Haskell 2.0 standard, but knowing which extensions are present
(independent of the compiler version) would be a very good thing
(listing syntactic extensions isn't an entirely useless thing; I'm sure
it would make Autoconf's job easier).

>     releaseDate    :: CalendarTime  -- ...
>     version        :: String        -- some combination of the above

<snip>

Jon Cast


More information about the Libraries mailing list