
#11662: Regression using NamedFieldPuns with qualified field names -------------------------------------+------------------------------------- Reporter: hesselink | Owner: Type: bug | Status: new Priority: normal | Milestone: Component: Compiler | Version: 8.0.1-rc2 Keywords: | Operating System: Unknown/Multiple Architecture: | Type of failure: GHC rejects Unknown/Multiple | valid program Test Case: | Blocked By: Blocking: | Related Tickets: Differential Rev(s): | Wiki Page: -------------------------------------+------------------------------------- I found a regression where code using the NamedFieldPuns extension and qualified field names doesn't compile with GHC 8 rc2, where it did with GHC 7.10. Minimal reproduction: {{{#!hs module Rec where data Rec = Rec { f :: Integer } -------------------- {-# LANGUAGE NamedFieldPuns #-} module Main where import Rec (Rec (Rec)) import qualified Rec g :: Rec -> Integer g (Rec { Rec.f }) = f }}} On GHC 8 this fails with: {{{ Main.hs:6:10: error: Qualified name in binding position: Rec.f }}} -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/11662 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler