Add a comment explaining CompleteMatchSig in HsBinds
authorMatthew Pickering <matthewtpickering@gmail.com>
Fri, 24 Feb 2017 17:37:19 +0000 (17:37 +0000)
committerMatthew Pickering <matthewtpickering@gmail.com>
Fri, 24 Feb 2017 17:38:05 +0000 (17:38 +0000)
[skip ci]

compiler/hsSyn/HsBinds.hs

index d985082..b39e25a 100644 (file)
@@ -853,6 +853,13 @@ data Sig name
   | SCCFunSig  SourceText      -- Note [Pragma source text] in BasicTypes
                (Located name)  -- Function name
                (Maybe (Located StringLiteral))
+       -- | A complete match pragma
+       --
+       -- > {-# COMPLETE C, D [:: T] #-}
+       --
+       -- Used to inform the pattern match checker about additional
+       -- complete matchings which, for example, arise from pattern
+       -- synonym definitions.
   | CompleteMatchSig SourceText (Located [Located name]) (Maybe (Located name))
 
 deriving instance (DataId name) => Data (Sig name)