diff options
author | Patrick Palka <patrick@parcs.ath.cx> | 2013-11-15 13:57:26 -0500 |
---|---|---|
committer | Simon Peyton Jones <simonpj@microsoft.com> | 2013-12-05 08:31:13 +0000 |
commit | 0f2a20bc882a918d39219b045a8db1ac7d9354fc (patch) | |
tree | e3c62ae70875a189b68fb11fc761b3ddbeb9e021 /compiler | |
parent | 8b642debfabe00377f47d461d31d70636bf0fce3 (diff) | |
download | haskell-0f2a20bc882a918d39219b045a8db1ac7d9354fc.tar.gz |
Suggest TemplateHaskell after encountering a naked top-level expression
Helps fix #7396
Diffstat (limited to 'compiler')
-rw-r--r-- | compiler/rename/RnSource.lhs | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/compiler/rename/RnSource.lhs b/compiler/rename/RnSource.lhs index 90175c0f91..624c3b60cb 100644 --- a/compiler/rename/RnSource.lhs +++ b/compiler/rename/RnSource.lhs @@ -1475,6 +1475,7 @@ add gp loc (SpliceD splice@(SpliceDecl _ flag)) ds ; return (gp, Just (splice, ds)) } where badImplicitSplice = ptext (sLit "Parse error: naked expression at top level") + $$ ptext (sLit "Perhaps you intended to use TemplateHaskell") add gp _ (QuasiQuoteD qq) ds -- Expand quasiquotes = do { ds' <- runQuasiQuoteDecl qq |