Refactor splice_exp in Parser.y
This small refactoring fixes a few annoyances:
- The code for constructing splices was duplicated between
atype
andsplice_exp
. - Locations were stripped with
unLoc
and added back withsL1
(now it is just amapLoc = fmap
call) - The return type of
reportEmptyDoubleQuotes
was overly specific. - The
mkTypedSplice
function was missing (it is now added by analogy withmkUntypedSplice
). - No longer needed and thus removed:
mkHsSpliceTy
,mkHsSpliceE
,mkHsSpliceTE
.