Commit 942c7148 authored by Ben Gamari's avatar Ben Gamari 🐢 Committed by Marge Bot

rename: Eliminate usage of mkVarOccUnique

Replacing it with `newSysName`. Fixes #17061.
parent 29c701c1
......@@ -67,8 +67,6 @@ import Data.Ord
import Data.Array
import qualified Data.List.NonEmpty as NE
import Unique ( mkVarOccUnique )
{-
************************************************************************
* *
......@@ -2198,10 +2196,10 @@ getMonadFailOp
| rebindableSyntax && overloadedStrings = do
(failExpr, failFvs) <- lookupSyntaxName failMName
(fromStringExpr, fromStringFvs) <- lookupSyntaxName fromStringName
let arg_lit = fsLit "arg"
arg_name = mkSystemVarName (mkVarOccUnique arg_lit) arg_lit
arg_syn_expr = mkRnSyntaxExpr arg_name
let body :: LHsExpr GhcRn =
let arg_lit = mkVarOcc "arg"
arg_name <- newSysName arg_lit
let arg_syn_expr = mkRnSyntaxExpr arg_name
body :: LHsExpr GhcRn =
nlHsApp (noLoc $ syn_expr failExpr)
(nlHsApp (noLoc $ syn_expr fromStringExpr)
(noLoc $ syn_expr arg_syn_expr))
......
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