- | unqualStyle sty mod_name occ = pprOccName occ
- -- Never qualify built-in syntax otherwise
- | debugStyle sty = sep [ppr mod_name <> dot <> pprOccName occ,
- hsep [text "{-"
- , if is_wired then ptext SLIT("(w)") else empty
- , pprUnique uniq
--- (overkill) , case mb_p of
--- Nothing -> empty
--- Just n -> brackets (ppr n)
- , text "-}"]]
- | otherwise = ppr mod_name <> dot <> pprOccName occ
- where
- mod_name = moduleName mod
+ | debugStyle sty = ppr mod <> dot <> ppr_occ_name occ
+ <> braces (hsep [if is_wired then ptext SLIT("(w)") else empty,
+ pprNameSpaceBrief (occNameSpace occ),
+ pprUnique uniq])
+ | BuiltInSyntax <- is_builtin = ppr_occ_name occ
+ -- never qualify builtin syntax
+ | unqualStyle sty mod occ = ppr_occ_name occ
+ | otherwise = ppr mod <> dot <> ppr_occ_name occ