1
0
mirror of https://github.com/tensorflow/haskell.git synced 2024-06-02 19:13:34 +02:00

Review comment addressed.

This commit is contained in:
Greg Steuck 2016-11-14 09:36:17 -08:00
parent 2bf1783d3f
commit 6398c6f944

View File

@ -118,9 +118,9 @@ sessionTracer = lens _sessionTracer (\g x -> g { _sessionTracer = x })
runSessionWithOptions :: Options -> Session a -> IO a
runSessionWithOptions options (Session m) =
FFI.withSession applyOptions $
\as rs -> do
\as rs ->
let initState = SessionState rs as (options ^. sessionTracer)
evalBuildT (runReaderT m initState)
in evalBuildT (runReaderT m initState)
where applyOptions opt = do
FFI.setSessionTarget (options ^. sessionTarget) opt
FFI.setSessionConfig (options ^. sessionConfig) opt