Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Give WITH-TRANSACTION a convenience return-value #13

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

tdrhq
Copy link

@tdrhq tdrhq commented Sep 5, 2020

Simple stuff, just a little bit of added convenience.

@kmcgivney
Copy link

I don't understand the difference between this approach and the prog2 that's there now. prog2 returns the second form right?

I think what we also need here is to allow the user to return multiple values. prog2 can't return multiple values.

Awkward though it might look the way to do it may be

(progn
  (database-start-transaction ,db)
  (multiple-value-prog1
    (progn
      ,@body)
    (mark-transaction-committed ,db)))

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants