diff --git a/CHANGES.markdown b/CHANGES.markdown
--- a/CHANGES.markdown
+++ b/CHANGES.markdown
@@ -1,3 +1,10 @@
+0.4.2 (26 November 2013)
+------------------------
+
+    - `buildDiagram` now accepts expressions of type `Diagram` or `IO
+      Diagram`: it just tries both.
+    - Add dependency on `mtl`.
+
 0.4.1 (24 November 2013)
 ------------------------
 
diff --git a/diagrams-builder.cabal b/diagrams-builder.cabal
--- a/diagrams-builder.cabal
+++ b/diagrams-builder.cabal
@@ -1,5 +1,5 @@
 name:                diagrams-builder
-version:             0.4.1
+version:             0.4.2
 synopsis:            hint-based build service for the diagrams graphics EDSL.
 
 description:         @diagrams-builder@ provides backend-agnostic tools for
@@ -47,6 +47,7 @@
                        Diagrams.Builder.Modules
                        Diagrams.Builder.CmdLine
   build-depends:       base >=4.2 && < 4.7,
+                       mtl >= 2.1 && < 2.2,
                        diagrams-lib >=0.6 && < 1.1,
                        hint ==0.3.*,
                        directory,
diff --git a/src/Diagrams/Builder.hs b/src/Diagrams/Builder.hs
--- a/src/Diagrams/Builder.hs
+++ b/src/Diagrams/Builder.hs
@@ -38,6 +38,7 @@
        ) where
 
 import           Control.Monad                       (guard, mplus, mzero)
+import           Control.Monad.Error                 (catchError)
 import           Control.Monad.Trans.Maybe           (MaybeT, runMaybeT)
 import           Crypto.Hash                         (Digest, MD5,
                                                       digestToHexByteString,
@@ -110,7 +111,8 @@
                  where hsenvArgv = words $ fromMaybe "" (lookup "PACKAGE_DB_FOR_GHC" env)
 
 -- | Interpret a diagram expression based on the contents of a given
---   source file, using some backend to produce a result.
+--   source file, using some backend to produce a result.  The
+--   expression can be of type @Diagram b v@ or @IO (Diagram b v)@.
 interpretDiagram
   :: forall b v.
      ( Typeable b, Typeable v
@@ -127,7 +129,7 @@
     args <- liftIO getHsenvArgv
     unsafeRunInterpreterWithArgs args $ do
       setDiagramImports m imps
-      d <- interpret dexp (as :: Diagram b v)
+      d <- interpret dexp (as :: Diagram b v) `catchError` const (interpret dexp (as :: IO (Diagram b v)) >>= liftIO)
       return (renderDia b opts d)
 
 -- | Pretty-print an @InterpreterError@.
@@ -153,8 +155,9 @@
                                   --   some extra information.
 
 -- | Build a diagram by writing the given source code to a temporary
---   module and interpreting the given expression.  Can return either
---   a parse error if the source does not parse, an interpreter error,
+--   module and interpreting the given expression, which can be of
+--   type @Diagram b v@ or @IO (Diagram b v)@.  Can return either a
+--   parse error if the source does not parse, an interpreter error,
 --   or the final result.
 buildDiagram
   :: ( Typeable b, Typeable v
