diff --git a/CHANGELOG.md b/CHANGELOG.md
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,3 +1,7 @@
+### 2.2.4
+
+- Support for GHC 8.6.5 (#63)
+
 ### 2.2.3
 
 - Removing an unnecessary optimization that was broken since 2.2
diff --git a/GPipe.cabal b/GPipe.cabal
--- a/GPipe.cabal
+++ b/GPipe.cabal
@@ -1,5 +1,5 @@
 name:           GPipe
-version:        2.2.3
+version:        2.2.4
 cabal-version:  >= 1.8
 build-type:     Simple
 author:         Tobias Bexelius
@@ -21,10 +21,10 @@
 
 library
   hs-source-dirs:   src
-  build-depends:    base >= 4.9 && < 4.11,
+  build-depends:    base >= 4.9 && < 5,
                     transformers >= 0.5.2 && < 0.6,
                     exception-transformers >= 0.3 && < 0.5,
-                    containers >= 0.5 && < 0.6,
+                    containers >= 0.5 && < 0.7,
                     Boolean >= 0.2 && <0.3,
                     hashtables >= 1.2 && < 1.3,
                     gl >= 0.8 && < 0.9,
diff --git a/src/Graphics/GPipe/Internal/Expr.hs b/src/Graphics/GPipe/Internal/Expr.hs
--- a/src/Graphics/GPipe/Internal/Expr.hs
+++ b/src/Graphics/GPipe/Internal/Expr.hs
@@ -267,9 +267,9 @@
                                return $ S $ return root
 
 shaderbaseAssignDef  (S shaderM) = do ul <- T.lift shaderM
-                                      x:xs <- get
-                                      put xs
-                                      T.lift $ tellAssignment' x ul
+                                      xs <- get
+                                      put $ tail xs
+                                      T.lift $ tellAssignment' (head xs) ul
                                       return ()
 shaderbaseReturnDef :: ReaderT (ExprM [String]) (State Int) (S x a)
 shaderbaseReturnDef = do i <- T.lift getNext
diff --git a/src/Graphics/GPipe/Internal/FragmentStream.hs b/src/Graphics/GPipe/Internal/FragmentStream.hs
--- a/src/Graphics/GPipe/Internal/FragmentStream.hs
+++ b/src/Graphics/GPipe/Internal/FragmentStream.hs
@@ -33,7 +33,7 @@
 
 -- | A @'FragmentStream' a @ is a stream of fragments of type @a@. You may append 'FragmentStream's using the 'Monoid' instance, and you
 --   can operate a stream's values using the 'Functor' instance (this will result in a shader running on the GPU).
-newtype FragmentStream a = FragmentStream [(a, FragmentStreamData)] deriving Monoid
+newtype FragmentStream a = FragmentStream [(a, FragmentStreamData)] deriving (Semigroup, Monoid)
 
 instance Functor FragmentStream where
         fmap f (FragmentStream xs) = FragmentStream $ map (first f) xs
diff --git a/src/Graphics/GPipe/Internal/PrimitiveArray.hs b/src/Graphics/GPipe/Internal/PrimitiveArray.hs
--- a/src/Graphics/GPipe/Internal/PrimitiveArray.hs
+++ b/src/Graphics/GPipe/Internal/PrimitiveArray.hs
@@ -139,9 +139,11 @@
 -- | An array of primitives
 newtype PrimitiveArray p a = PrimitiveArray {getPrimitiveArray :: [PrimitiveArrayInt p a]}
 
+instance Semigroup (PrimitiveArray p a) where
+    PrimitiveArray a <> PrimitiveArray b = PrimitiveArray (a ++ b)
+
 instance Monoid (PrimitiveArray p a) where
     mempty = PrimitiveArray []
-    mappend (PrimitiveArray a) (PrimitiveArray b) = PrimitiveArray (a ++ b)
 
 instance Functor (PrimitiveArray p) where
     fmap f (PrimitiveArray xs) = PrimitiveArray  $ fmap g xs
diff --git a/src/Graphics/GPipe/Internal/PrimitiveStream.hs b/src/Graphics/GPipe/Internal/PrimitiveStream.hs
--- a/src/Graphics/GPipe/Internal/PrimitiveStream.hs
+++ b/src/Graphics/GPipe/Internal/PrimitiveStream.hs
@@ -46,7 +46,7 @@
 --   can operate a stream's vertex values using the 'Functor' instance (this will result in a shader running on the GPU).
 --   You may also append 'PrimitiveStream's using the 'Monoid' instance, but if possible append the origin 'PrimitiveArray's instead, as this will create more optimized
 --   draw calls.
-newtype PrimitiveStream t a = PrimitiveStream [(a, (Maybe PointSize, PrimitiveStreamData))] deriving Monoid
+newtype PrimitiveStream t a = PrimitiveStream [(a, (Maybe PointSize, PrimitiveStreamData))] deriving (Semigroup, Monoid)
 
 instance Functor (PrimitiveStream t) where
         fmap f (PrimitiveStream xs) = PrimitiveStream $ map (first f) xs
diff --git a/src/Graphics/GPipe/Internal/Texture.hs b/src/Graphics/GPipe/Internal/Texture.hs
--- a/src/Graphics/GPipe/Internal/Texture.hs
+++ b/src/Graphics/GPipe/Internal/Texture.hs
@@ -1134,7 +1134,7 @@
 fetchFunc s off coord lod vToS civToS = do
     c <- vToS coord
     l <- unS lod
-    return $ "fetch" ++ offName off ++ '(' : s ++ ',' : c ++ ',': l ++ o ++ ")"
+    return $ "texelFetch" ++ offName off ++ '(' : s ++ ',' : c ++ ',': l ++ o ++ ")"
   where
     o = offParam off civToS
 
