Add support for LINE pragma in template-haskell
authorEric Mertens <emertens@gmail.com>
Tue, 7 Oct 2014 13:48:37 +0000 (08:48 -0500)
committerAustin Seipp <austin@well-typed.com>
Tue, 7 Oct 2014 13:48:38 +0000 (08:48 -0500)
commitadcb9dbc0bfb6a7dd3f4f746e2f8cd620745db75
tree5ebde7824e00cfaf08c4ab39e15f8e45d992862e
parent2ee252783b732649f6075b769bd6b964e3823400
Add support for LINE pragma in template-haskell

Summary:
Provide a way to generate {-# LINE #-} pragmas when generating
Decs in Template Haskell. This allows more meaningful line
numbers to be reported in compile-time errors for dynamically
generated code.

Test Plan: Run test suite

Reviewers: austin, hvr

Reviewed By: austin

Subscribers: hvr, simonmar, ezyang, carter, thomie

Differential Revision: https://phabricator.haskell.org/D299
compiler/hsSyn/Convert.lhs
docs/users_guide/7.10.1-notes.xml
docs/users_guide/glasgow_exts.xml
libraries/template-haskell/Language/Haskell/TH.hs
libraries/template-haskell/Language/Haskell/TH/Lib.hs
libraries/template-haskell/Language/Haskell/TH/Ppr.hs
libraries/template-haskell/Language/Haskell/TH/Syntax.hs
testsuite/tests/th/TH_linePragma.hs [new file with mode: 0644]
testsuite/tests/th/TH_linePragma.stderr [new file with mode: 0644]
testsuite/tests/th/all.T