id,summary,reporter,owner,description,type,status,priority,milestone,component,version,severity,resolution,keywords,cc,difficulty,ghcversion,platform
370,Check that packages declare language extensions accurately,guest,,"We'd like to make it possible to ensure all code on hackage lists precisely the -X extensions it uses. 

This kind of thing

     -XEmptyDataDecls -XTypeSynonymInstances -XMultiParamTypeClasses -XFlexibleInstances -XRank2Types -XScopedTypeVariables -XDeriveDataTypeable

Now, these should be listed in both the .cabal file, and in individual modules that require the extensions. We can check this by loading the modules in ghci.

The end result: we'd be able to filter on extensions. Researchers would be able to see precisely which extensions are used, and in what packages.

A simple 'is this type correct' script:

{{{
#!/bin/sh

echo ""Checking type correctness ... ""

f=`mktemp`

for i in *.hs ; do
     ghci -cpp -Iinclude -v0 $i < /dev/null
done > $f 2>&1

if cmp -s $f /dev/null ; then
    echo ""Passed""
    true
else
    echo ""Failed""
    cat $f
    false
fi
}}}",defect,new,normal,Cabal-2.0,Cabal library,HEAD,normal,,,,normal,6.8.2,
