Availability:built-in
[nondet]current_transaction(-Goal)True when called inside a transaction running Goal. This
predicate generates candidates from the current (nested) transaction
outward.
Goal is a plain goal if the calling context module is the
same as matching transaction/1
or snapshot/1
and a qualified callable term otherwise. Note that this only enumerates
transactions in the current thread.