[Git][ghc/ghc][wip/int-index/list-tuple-cleanup] 13 commits: compiler: Fix pretty printing of ticked prefix constructors (#24237)

Vladislav Zavialov (@int-index) gitlab at gitlab.haskell.org
Fri Aug 23 01:17:31 UTC 2024



Vladislav Zavialov pushed to branch wip/int-index/list-tuple-cleanup at Glasgow Haskell Compiler / GHC


Commits:
5f972bfb by Zubin Duggal at 2024-08-21T03:18:15-04:00
compiler: Fix pretty printing of ticked prefix constructors (#24237)

- - - - -
ef0a08e7 by Mike Pilgrem at 2024-08-21T03:18:57-04:00
Fix #15773 Clarify further -rtsopts 'defaults' in docs

- - - - -
05a4be58 by Sebastian Graf at 2024-08-21T03:19:33-04:00
Improve efficiency of `assertError` (#24625)

... by moving `lazy` to the exception-throwing branch.
It's all documented in `Note [Strictness of assertError]`.

- - - - -
c29b2b5a by sheaf at 2024-08-21T13:11:30-04:00
GHCi debugger: drop record name spaces for Ids

When binding new local variables at a breakpoint, we should create
Ids with variable namespace, and not record field namespace. Otherwise
the rest of the compiler falls over because the IdDetails are wrong.

Fixes #25109

- - - - -
bd82ac9f by Hécate Kleidukos at 2024-08-21T13:12:12-04:00
base: Final deprecation of GHC.Pack

The timeline mandated by #21461 has come to its term and after two years
and four minor releases, we are finally removing GHC.Pack from base.

Closes #21536

- - - - -
5092dbff by Sylvain Henry at 2024-08-21T13:12:54-04:00
JS: support rubbish static literals (#25177)

Support for rubbish dynamic literals was added in #24664. This patch
does the same for static literals.

Fix #25177

- - - - -
b5a2c061 by Phil de Joux at 2024-08-21T13:13:33-04:00
haddock docs: prefix comes before, postfix comes after

- - - - -
6fde3685 by Marcin Szamotulski at 2024-08-21T23:15:39-04:00
haddock: include package info with --show-interface

- - - - -
7e02111b by Andreas Klebinger at 2024-08-21T23:16:15-04:00
Document the (x86) SIMD macros.

Fixes #25021.

- - - - -
05116c83 by Rodrigo Mesquita at 2024-08-22T10:37:44-04:00
ghc-internal: Derive version from ghc's version

Fixes #25005

- - - - -
73f5897d by Ben Gamari at 2024-08-22T10:37:44-04:00
base: Deprecate GHC.Desugar

See https://github.com/haskell/core-libraries-committee/issues/216.

This will be removed in GHC 9.14.

- - - - -
821d0a9a by Cheng Shao at 2024-08-22T10:38:22-04:00
compiler: Store ForeignStubs and foreign C files in interfaces

This data is used alongside Core bindings to reconstruct intermediate
build products when linking Template Haskell splices with bytecode.

Since foreign stubs and files are generated in the pipeline, they were
lost with only Core bindings stored in interfaces.

The interface codec type `IfaceForeign` contains a simplified
representation of `ForeignStubs` and the set of foreign sources that
were manually added by the user.

When the backend phase writes an interface, `mkFullIface` calls
`encodeIfaceForeign` to read foreign source file contents and assemble
`IfaceForeign`.

After the recompilation status check of an upstream module,
`initWholeCoreBindings` calls `decodeIfaceForeign` to restore
`ForeignStubs` and write the contents of foreign sources to the file
system as temporary files.
The restored foreign inputs are then processed by `hscInteractive` in
the same manner as in a regular pipeline.

When linking the stub objects for splices, they are excluded from suffix
adjustment for the interpreter way through a new flag in `Unlinked`.

For details about these processes, please consult Note [Foreign stubs
and TH bytecode linking].

Metric Decrease:
    T13701

- - - - -
3a5430c3 by Vladislav Zavialov at 2024-08-23T04:17:01+03:00
Rework built-in and punned names (#25174, #25179, #25180, #25182)

This patch rewrites part of the logic for dealing with built-in and
punned names, making it more principled and fixing a few bugs.

* Kill off filterCTuple. Its purpose was to improve pretty-printing of
  constraint tuples, and the appropriate place for this is namePun_maybe.

* Remove unitTyCon, unboxedUnitTyCon, and soloTyCon from wiredInTyCons.
  Their inclusion in the list was a workaround for shoddy logic in
  lookupOrigNameCache. Now we treat tuples of all arities uniformly.

* In isBuiltInOcc_maybe, only match on actual built-in syntax, e.g. "FUN"
  shouldn't be there (#25174). Also take ListTuplePuns into account (#25179).

* When matching OccNames, use the ShortByteString directly to avoid
  potentially costly conversions to ByteString and String.

* Introduce isInfiniteFamilyOrigName_maybe, a purpose-built helper for
  looking up tuples/sums in the OrigNameCache. This clears up the previously
  convoluted relation between the orig name cache and built-in syntax.

* Fix #13776 directly in the Outputable RdrName instance instead of the
  workaround in thOrigRdrName. Reuse lookupOrigNameCache to eliminate
  the need for isPunOcc_maybe.

* Classify MkSolo and MkSolo# as UserSyntax, thus fixing whole-module
  reexports (#25182).

* Teach valid-hole-fits about tuples, unboxed tuples, and unboxed sums,
  up to a certain arity (#25180).

* Drop the unnecessary special case for unary constraint tuples in the
  type checker (finish_tuple). It was a workaround for the lack of CSolo.

* Update Notes and other comments, add tests.

- - - - -


30 changed files:

- .gitignore
- + a.out
- compiler/GHC/Builtin/Names.hs
- compiler/GHC/Builtin/Types.hs
- compiler/GHC/Builtin/Uniques.hs
- compiler/GHC/Cmm/CLabel.hs
- compiler/GHC/Driver/Main.hs
- compiler/GHC/Driver/Pipeline.hs
- compiler/GHC/Driver/Pipeline/Execute.hs
- compiler/GHC/HsToCore/Usage.hs
- compiler/GHC/Iface/Make.hs
- compiler/GHC/Iface/Recomp.hs
- compiler/GHC/Iface/Type.hs
- compiler/GHC/IfaceToCore.hs
- compiler/GHC/Linker/Deps.hs
- compiler/GHC/Linker/Loader.hs
- compiler/GHC/Linker/Types.hs
- compiler/GHC/Parser/Errors/Ppr.hs
- compiler/GHC/Plugins.hs
- compiler/GHC/Rename/Env.hs
- compiler/GHC/Runtime/Eval.hs
- compiler/GHC/StgToJS/Literal.hs
- compiler/GHC/SysTools/Cpp.hs
- compiler/GHC/Tc/Errors/Hole.hs
- compiler/GHC/Tc/Errors/Ppr.hs
- compiler/GHC/Tc/Gen/HsType.hs
- compiler/GHC/Tc/Gen/Splice.hs
- compiler/GHC/ThToHs.hs
- compiler/GHC/Types/Id.hs
- compiler/GHC/Types/Name.hs


The diff was not included because it is too large.


View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/54a6ae807de0e7deac558e19038c02d7e2cc675f...3a5430c3f78730a30f88ac6212de762c7a6f9832

-- 
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/54a6ae807de0e7deac558e19038c02d7e2cc675f...3a5430c3f78730a30f88ac6212de762c7a6f9832
You're receiving this email because of your account on gitlab.haskell.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/ghc-commits/attachments/20240822/04e10d16/attachment-0001.html>


More information about the ghc-commits mailing list