1
1
mirror of https://github.com/github/semantic.git synced 2025-01-05 22:28:10 +03:00

update introduceLocals helper function

This commit is contained in:
Ayman Nadeem 2020-05-13 11:34:07 -04:00
parent 3c1782b311
commit b4fd39a156

View File

@ -326,7 +326,7 @@ introduceLocals ::
] ->
m ()
introduceLocals params = for_ params $ \param -> case param of
Prj Rb.BlockParameter {name = Rb.Identifier {text = lvar}} -> modify (lvar :)
Prj Rb.BlockParameter {name = Parse.Success (Rb.Identifier {text = lvar})} -> modify (lvar :)
Prj Rb.DestructuredParameter {extraChildren} -> introduceLocals extraChildren
Prj Rb.HashSplatParameter {name = Just Rb.Identifier {text = lvar}} -> modify (lvar :)
Prj Rb.Identifier {text = lvar} -> modify (lvar :)