This used to be a shortcoming of the compiler, where the Template Haskell datatype for declarations is not even capable of storing a stand-alone deriving instance (see http://hackage.haskell.org/packages/archive/template-haskell/2.8.0.0/doc/html/Language-Haskell-TH-Syntax.html#t:Dec).
Since 7.10, though, this bug has been fixed. (Thanks to @VladimirStill for pointing this out in a comment below.)