Skip to content

Refactor splice_exp in Parser.y

Vladislav Zavialov requested to merge wip/splice-parsing into master

This small refactoring fixes a few annoyances:

  1. The code for constructing splices was duplicated between atype and splice_exp.
  2. Locations were stripped with unLoc and added back with sL1 (now it is just a mapLoc = fmap call)
  3. The return type of reportEmptyDoubleQuotes was overly specific.
  4. The mkTypedSplice function was missing (it is now added by analogy with mkUntypedSplice).
  5. No longer needed and thus removed: mkHsSpliceTy, mkHsSpliceE, mkHsSpliceTE.
Edited by Vladislav Zavialov

Merge request reports