Generalise `Control.Monad.{foldM,foldM_}` to `Foldable` (#9586)

With this change `Control.Monad.foldM` becomes an alias for
`Data.Foldable.foldlM`.

Reviewed By: austin, ekmett

Differential Revision: https://phabricator.haskell.org/D251
Remove redundant explicit `Prelude` imports

Since they're implied by the lack of `NoImplicitPrelude`
Python 3 support, second attempt (Trac #9184)

Summary:
This is a fixup of https://phabricator.haskell.org/D233

The only difference is in findTFiles (first commit), which
previously broke Windows runner; now I translated literally
instead attempting to improve it, and checked it works.

Test Plan:
I used validate under 2,3 on Linux and under 2 on msys2.
On Windows I've seen a large number of failures, but they don't
seem to be connected with the patch.

Reviewers: hvr, simonmar, thomie, austin

Reviewed By: austin

Subscribers: thomie, carter, ezyang, simonmar

Differential Revision: https://phabricator.haskell.org/D310

GHC Trac Issues: #9184
Refactor module imports in base

This commit removes a couple of

  {-# OPTIONS_GHC -fno-warn-unused-imports #-}

by cleaning up the imports, as well as ensuring that all modules in the
GHC.* hierarchy avoid importing the `Prelude` module to clean-up the
import graph a bit.
Indentation and non-semantic changes only.

Summary:
Get these lines fitting in 80 columns, and replace ptext (sLit ...) with text

Signed-off-by: Edward Z. Yang <ezyang@cs.stanford.edu>

Test Plan: validate

Reviewers: simonmar, austin

Subscribers: thomie, carter, ezyang, simonmar

Differential Revision: https://phabricator.haskell.org/D342
Sync up `containers` submodule to latest `master`-tip

This updates `containers` to provide more specialised `Foldable`
instance methods, see also

  https://github.com/haskell/containers/issues/56

for more details.
Revert "Fix typo in section name: no leading period."

This reverts commit e8dac6dc60beea863c3a5daded68f5157ab546fb.
Revert "Check for staticclosures section in Windows linker."

This reverts commit 2fc0c6cf594731f343b4f8a5b3ecf9e72db4c3c0.
Revert "Rename _closure to _static_closure, apply naming consistently."

This reverts commit 35672072b4091d6f0031417bc160c568f22d0469.

Conflicts:
	compiler/main/DriverPipeline.hs
Revert "Properly generate info tables for static closures in C--."

This reverts commit 178eb9060f369b216f3f401196e28eab4af5624d.
Revert "BC-breaking changes to C-- CLOSURE syntax."

This reverts commit 3b5a840bba375c4c4c11ccfeb283f84c3a1ef22c.
Revert "Place static closures in their own section."

This reverts commit b23ba2a7d612c6b466521399b33fe9aacf5c4f75.

Conflicts:
	compiler/cmm/PprCmmDecl.hs
	compiler/nativeGen/PPC/Ppr.hs
	compiler/nativeGen/SPARC/Ppr.hs
	compiler/nativeGen/X86/Ppr.hs
Update Haddock submodule

As requested by Yuras Shumovich, this updates Haddock to include
.arcconfig and .arclint files, so diffs for GHC patches can go into
Phabricator.

Signed-off-by: Austin Seipp <austin@well-typed.com>
Revert "rts/PrimOps.cmm: follow '_static_closure' update"

This reverts commit eb191ab6c85f4b668a6e9151dcecaf1f1e7ec7c2.

Follows revert of STATIC_CLOSURE and restores UNREG build.
Test #9692 in th/T9692
Clarify location of Note. Comment change only.
Reify data family instances correctly.

Summary:
Fix #9692.

The reifier didn't account for the possibility that data/newtype
instances are sometimes eta-reduced. It now eta-expands as necessary.

Test Plan: th/T9692

Reviewers: simonpj, austin

Subscribers: thomie, carter, ezyang, simonmar

Differential Revision: https://phabricator.haskell.org/D355
Update primitive, vector, and dph submodules.
Make Applicative-Monad fixes for tests.
Updated testsuite/.gitignore to cover artifacts on Windows.

Test Plan: git status after a test run

Reviewers: austin

Reviewed By: austin

Subscribers: thomie, carter, ezyang, simonmar

Differential Revision: https://phabricator.haskell.org/D333

GHC Trac Issues: #9679