Avoid find_tycon panic if datacon is not in scope
authorAdam Gundry <adam@well-typed.com>
Fri, 30 Dec 2016 02:30:41 +0000 (02:30 +0000)
committerRaspbian forward porter <root@raspbian.org>
Fri, 30 Dec 2016 02:30:41 +0000 (02:30 +0000)
commitc79d882645db49a2ef6dd6f85070c80685ed533c
treecbdbcd5c9136143777e1394f5710ea86ae52f194
parenta7ed2a060751152d83ae9bbd0170e39a823b322c
Avoid find_tycon panic if datacon is not in scope

When using TH to splice expressions involving record field construction,
the parent datacon may not be in scope.  We shouldn't panic about this,
because we will be renaming Exact RdrNames which don't require any
disambiguation.

Reviewers: austin, bgamari
Reviewed By: bgamari
Differential Revision: https://phabricator.haskell.org/D2321
GHC Trac Issues: #12130

Origin: upstream, https://git.haskell.org/ghc.git/commitdiff/694e0f3a08030

Gbp-Pq: Name find-tycon-panic
compiler/rename/RnPat.hs