Home My Page Projects Code Snippets Project Openings SML/NJ
Summary Activity Forums Tracker Lists Tasks Docs Surveys News SCM Files

SCM Repository

[smlnj] View of /sml/trunk/src/MLRISC/library/transaction.sml
ViewVC logotype

View of /sml/trunk/src/MLRISC/library/transaction.sml

Parent Directory Parent Directory | Revision Log Revision Log


Revision 245 - (download) (annotate)
Sat Apr 17 18:47:12 1999 UTC (20 years, 5 months ago) by monnier
Original Path: sml/branches/SMLNJ/src/MLRISC/library/transaction.sml
File size: 328 byte(s)
version 110.16
functor TransactionFn(Log : TRANSACTION_LOG) : TRANSACTION =
struct

   exception Abort

   fun transaction default func =
   let
       val _ = Log.begin()
       val x = func()
       val _ = Log.commit()
   in
       x
   end
   handle Abort => (Log.abort(); default)
	| e     => (Log.abort(); raise e)

end

(*
 * $Log$
 *)

root@smlnj-gforge.cs.uchicago.edu
ViewVC Help
Powered by ViewVC 1.0.0