Skip to content
This repository was archived by the owner on Apr 1, 2025. It is now read-only.

Commit 0515d7c

Browse files
committed
Let-bind the function extending each value in the cell.
1 parent c30e5ff commit 0515d7c

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

semantic-core/src/Analysis/ScopeGraph.hs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,8 @@ scopeGraphAnalysis = Analysis{..}
102102
ref <- asks Ref
103103
bindLoc <- asks (Map.lookup addr)
104104
cell <- gets (Map.lookup addr >=> nonEmpty . Set.toList)
105-
maybe (pure Nothing) (foldMapA (pure . Just . mappend (extendBinding addr ref bindLoc))) cell
105+
let extending = mappend (extendBinding addr ref bindLoc)
106+
maybe (pure Nothing) (foldMapA (pure . Just . extending)) cell
106107
assign addr v = do
107108
ref <- asks Ref
108109
bindLoc <- asks (Map.lookup addr)

0 commit comments

Comments
 (0)