Commit b3ae47ca authored by Sergei Trofimovich's avatar Sergei Trofimovich

don't allow AsmTempLabel in UNREG mode (Trac #14264)

AsmTempLabel is really a label that describes
label in assembly output (or equivalent like LLVM IR).

Unregisterised build does not handle it correctly.

This change does not fix UNREG build failure in
Ticket #14264 but reverts back to panic:
    pprCLbl AsmTempLabel
Signed-off-by: default avatarSergei Trofimovich <slyfox@gentoo.org>
parent 9c7d0657
......@@ -197,6 +197,7 @@ data CLabel
{-# UNPACK #-} !Unique -- Unique says which case expression
CaseLabelInfo
-- | Local temporary label used for native (or LLVM) code generation
| AsmTempLabel
{-# UNPACK #-} !Unique
......@@ -1092,6 +1093,7 @@ instance Outputable CLabel where
pprCLabel :: Platform -> CLabel -> SDoc
pprCLabel platform (AsmTempLabel u)
| not (platformUnregisterised platform)
= getPprStyle $ \ sty ->
if asmStyle sty then
ptext (asmTempLabelPrefix platform) <> pprUniqueAlways u
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment