[ Advanced Control and Suspensions | Reference Manual | Alphabetic Index ]

attached_suspensions(+Trigger, -SuspensionList)

Retrieves a list of all suspensions attached to the symbolic trigger Trigger.
Trigger
An atom
SuspensionList
Variable or List.

Description

Retrieves all suspensions (dead or live) attached to the trigger Trigger, and returns them in SuspensionList.

Note that you can use sort/2 to eliminate duplicates, and is_suspension/1 to filter out dead suspensions.

Modes and Determinism

Examples

?- suspend(true, 3, trigger(hello)), attached_suspensions(hello, S).
S = ['SUSP-_207-susp']
Delayed goals:
        true
Yes (0.00s cpu)

See Also

suspensions / 1, suspensions / 2, subcall / 2, get_suspension_data / 3, sort / 2, is_suspension / 1