Skip to content
Snippets Groups Projects
Forked from Glasgow Haskell Compiler / GHC
5258 commits behind the upstream repository.
Duncan Coutts's avatar
Duncan Coutts authored
All the changes are in fact not changes at all.

Previously, the IoSubSystem data type was defined in GHC.RTS.Flags and
exported from both GHC.RTS.Flags and GHC.IO.SubSystem. Now, the data
type is defined in GHC.IO.SubSystem and still exported from both
modules.

Therefore, the same exports and same instances are still available from
both modules. But the base-exports records only the defining module, and
so it looks like a change when it is fully compatible.

Related: we do add a deprecation to the export of the type via
GHC.RTS.Flags, telling people to use the export from GHC.IO.SubSystem.

Also the sort order for some unrelated Show instances changed. No idea
why.

The same changes apply in the other versions, with a few more changes
due to sort order weirdness.
1adc6fa4
History

Interface stability testing

The tests in this directory verify that the interfaces of exposed by GHC's core libraries do not inadvertently change. They use the utils/dump-decls utility to dump all exported declarations of all exposed modules for the following packages:

  • base

These are compared against the expected exports in the test's corresponding .stdout file.

Updating expected output

The base-exports test in particular has rather platform-dependent output. Consequently, updating its output can be a bit tricky. There are two ways by which one can do this:

  • Extrapolation: The various platforms' base-exports.stdout files are similar enough that one can often apply the same patch of one file to the others. For instance:

    for f in testsuite/tests/interface-stability/base-exports.stdout-*; do
      git show testsuite/tests/interface-stability \
        | sed -e "s/base-exports.stdout/$(basename $f)/" \
        | patch -p1
    done

    In the case of conflicts, increasing the fuzz factor (using -F) can be quite effective.

  • Using CI: Each CI job produces a tarball, unexpected-test-output.tar.gz, which contains the output produced by the job's failing tests. Simply download this tarball and extracting the appropriate base-exports.stdout-* files into this directory.