-- | Writes a raw audio expression to a file.
runRawdio
  :: Rawdio -- ^ Audio expression to evaluate.
  -> FilePath -- ^ Output WAV file to generate.
  -> IO ()
runRawdio raw out = withSystemTempDirectory "scissors" $ \tempdir -> do
  f <- runRawdioIn tempdir raw
  copyFile f out

-- | Writes a raw audio expression to a new file in a temporary directory.
runRawdio
  :: Rawdio -- ^ Audio expression to evaluate.
  -> FilePath -- ^ Output WAV file to generate.
  -> IO ()
runRawdio raw out = withSystemTempDirectory "scissors" $ \tempdir -> do
  f <- runRawdioIn tempdir raw
  copyFile f out

-- | Writes a raw audio expression to a new file in a temporary directory.
runRawdio raw out = withSystemTempDirectory "scissors" $ \tempdir -> do
  f <- runRawdioIn tempdir raw
  copyFile f out

-- | Writes a raw audio expression to a new file in a temporary directory.