Welcome to the CHICKEN Scheme pasting service

define-in-transaction added by andyjpb on Thu Jul 12 16:50:08 2018

(define-syntax define-in-transaction
  (syntax-rules ()
		((define-in-transaction signature exp exp* ...)
		 (define signature
		   (let ((body (lambda () exp exp* ...)))
		     (if (internal-call?)
		       (begin
			 (assert (eq? #f (autocommit? (db-ctx)))
				 (conc "define-in-transaction: Internal calls to API procedures must already be inside a transaction by we are not!"))
			 (with-savepoint-transaction
			   (db-ctx)
			   body))
		       (with-transaction
			 (db-ctx)
			 body)))))))

Your annotation:

Enter a new annotation:

Your nick:
The title of your paste:
Your paste (mandatory) :
What type of object does `for-each' expect as second argument?
Visually impaired? Let me spell it for you (wav file) download WAV