Factor out HsSCC/HsCoreAnn/HsTickPragma into HsPragE

This is a refactoring with no user-visible changes (except for GHC API
users). Consider the HsExpr constructors that correspond to user-written
pragmas:

  HsSCC         representing  {-# SCC ... #-}
  HsCoreAnn     representing  {-# CORE ... #-}
  HsTickPragma  representing  {-# GENERATED ... #-}

We can factor them out into a separate datatype, HsPragE. It makes the
code a bit tidier, especially in the parser.

Before this patch:

  hpc_annot :: { Located ( (([AddAnn],SourceText),(StringLiteral,(Int,Int),(Int,Int))),
                           ((SourceText,SourceText),(SourceText,SourceText))
                         ) }

After this patch:

  prag_hpc :: { Located ([AddAnn], HsPragE GhcPs) }
22 jobs for master in 464 minutes and 7 seconds (queued for 5 seconds)
Status Job ID Name Coverage
  Lint
passed #212720
lint
lint-linters

00:00:18

passed #212723
lint
lint-submods-branch

00:00:22

passed #212721
lint
lint-testsuite

00:00:20

passed #212722
lint
typecheck-testsuite

00:00:19

 
  Quick Build
passed #212724
x86_64-linux
hadrian-ghc-in-ghci

00:17:49

 
  Build
passed #212727
x86_64-linux
release-x86_64-linux-deb9-dwarf

01:41:43

passed #212726
x86_64-linux
validate-x86_64-linux-deb9-debug

02:33:42

passed #212725
x86_64-linux
validate-x86_64-linux-deb9-hadrian

02:02:49

 
  Full Build
failed #212730
aarch64-linux allowed to fail
validate-aarch64-linux-deb9

03:17:40

failed #212731
armv7-linux allowed to fail
validate-armv7-linux-deb9

03:25:31

passed #212732
x86_64-linux
validate-i386-linux-deb9

01:53:59

passed #212729
x86_64-darwin
validate-x86_64-darwin

01:03:56

passed #212733
x86_64-linux
validate-x86_64-linux-deb9-integer-simple

01:11:38

passed #212728
x86_64-linux
validate-x86_64-linux-deb9-unreg-hadrian

04:27:02

passed #212734
x86_64-linux
validate-x86_64-linux-fedora27

01:54:53

failed #212736
x86_64-windows allowed to fail
validate-x86_64-windows

00:04:18

failed #212735
x86_64-windows allowed to fail
validate-x86_64-windows-hadrian

00:04:10

 
  Cleanup
passed #212737
x86_64-darwin
cleanup-darwin

00:00:12

 
  Packaging
failed #212738
x86_64-linux allowed to fail
doc-tarball

00:00:35

 
  Testing
manual #212739
x86_64-linux allowed to fail manual
hackage
passed #212740
x86_64-linux
perf-nofib

00:21:56

 
  Deploy
failed #212741
x86_64-linux allowed to fail
pages

00:02:05

 
Name Stage Failure
failed
validate-armv7-linux-deb9 Full Build
Uploading artifacts...
ghc-armv7-linux-deb9.tar.xz: found 1 matching files
junit.xml: found 1 matching files

performance-metrics.tsv: found 1 matching files

Uploading artifacts to coordinator... ok
id=212731 responseStatus=201 Created token=zxgCX8PK
Uploading artifacts...
junit.xml: found 1 matching files

Uploading artifacts to coordinator... ok
id=212731 responseStatus=201 Created token=zxgCX8PK
ERROR: Job failed: exit code 1
failed
validate-x86_64-windows-hadrian Full Build
Runtime platform                                    arch=amd64 os=windows pid=8332 revision=1f513601 version=11.10.1
WARNING: ghc.tar.xz: no matching files
WARNING: junit.xml: no matching files
ERROR: No files to upload
Uploading artifacts...
Runtime platform
arch=amd64 os=windows pid=8412 revision=1f513601 version=11.10.1
WARNING: junit.xml: no matching files
ERROR: No files to upload
ERROR: Job failed: exit status 1
failed
validate-x86_64-windows Full Build
Runtime platform                                    arch=amd64 os=windows pid=7580 revision=1f513601 version=11.10.1
WARNING: $BIN_DIST_PREP_TAR_COMP: no matching files
WARNING: junit.xml: no matching files
ERROR: No files to upload
Uploading artifacts...
Runtime platform
arch=amd64 os=windows pid=8272 revision=1f513601 version=11.10.1
WARNING: junit.xml: no matching files
ERROR: No files to upload
ERROR: Job failed: exit status 1
failed
validate-aarch64-linux-deb9 Full Build
Uploading artifacts...
ghc-aarch64-linux-deb9.tar.xz: found 1 matching files
junit.xml: found 1 matching files

performance-metrics.tsv: found 1 matching files

Uploading artifacts to coordinator... ok
id=212730 responseStatus=201 Created token=zyxssgJk
Uploading artifacts...
junit.xml: found 1 matching files

Uploading artifacts to coordinator... ok
id=212730 responseStatus=201 Created token=zyxssgJk
ERROR: Job failed: exit code 1
failed
doc-tarball Packaging
Synchronizing submodule url for 'utils/hsc2hs'
$ git submodule update --init --recursive
$ git checkout .gitmodules
$ git fetch https://gitlab.haskell.org/ghc/ghc-performance-notes.git refs/notes/perf:refs/notes/perf || true
From https://gitlab.haskell.org/ghc/ghc-performance-notes
3984782112..b671d9c1d7 refs/notes/perf -> refs/notes/perf
$ if [ ! -f "$LINUX_BINDIST" ]; then # collapsed multi-line command
Error: ghc-x86_64-mingw32.tar.xz does not exist. Did the 64-bit Windows job fail?
ERROR: Job failed: exit code 1
failed
pages Deploy
Synchronizing submodule url for 'utils/hsc2hs'
$ git submodule update --init --recursive
$ git checkout .gitmodules
$ git fetch https://gitlab.haskell.org/ghc/ghc-performance-notes.git refs/notes/perf:refs/notes/perf || true
$ mkdir -p public/doc
$ tar -xf haddock.html.tar.xz -C public/doc
tar: haddock.html.tar.xz: Cannot open: No such file or directory
tar: Error is not recoverable: exiting now
ERROR: Job failed: exit code 1