diff --git a/qc-tests/Tests.hs b/qc-tests/Tests.hs
--- a/qc-tests/Tests.hs
+++ b/qc-tests/Tests.hs
@@ -2,6 +2,7 @@
 {-# LANGUAGE DeriveGeneric #-}
 {-# LANGUAGE FlexibleInstances #-}
 {-# LANGUAGE StandaloneDeriving #-}
+{-# LANGUAGE CPP #-}
 
 {-# OPTIONS_GHC -fno-warn-orphans #-}
 
@@ -19,6 +20,11 @@
 import Test.SmartCheck.Types
 
 --------------------------------------------------------------------------------
+
+#if MIN_VERSION_containers(0,5,10)
+#else
+deriving instance Generic (Tree a)
+#endif
 
 instance (SubTypes a) => SubTypes (Tree a)
 
diff --git a/smartcheck.cabal b/smartcheck.cabal
--- a/smartcheck.cabal
+++ b/smartcheck.cabal
@@ -1,5 +1,5 @@
 Name:                smartcheck
-Version:             0.2.3
+Version:             0.2.4
 Synopsis:            A smarter QuickCheck.
 Homepage:            https://github.com/leepike/SmartCheck
 Description:         See the README.md: fast, small shrinking and generalization of failing test-cases from QuickCheck.
