Std. Process
(Cure Standard Library v0.37.2)
View Source
Compatibility façade for process-signal operations.
The unrestricted process algebra formerly exposed unindexed Pid and Ref
primitives and declared effectful BEAM BIFs as pure functions. Those types
and that purity lie were retired by the formal OTP surface. New code should
use Std.Otp directly; this module keeps the familiar signal-operation
namespace while preserving exactly the same indexed handles and Effect
results as Std.Otp.
Examples
use Std.Otp
fn current_pid() -> Effect(Pid(Atom)) =
Std.Process.self()
Summary
Functions
Remove a monitor and flush any pending DOWN message for ref.
Delegates to Std.Otp.demonitor/1.
Report whether the local process pid is currently alive.
Delegates to Std.Otp.is_alive/1.
Establish a bidirectional link between the calling process and pid.
Delegates to Std.Otp.link/1.
Start monitoring pid with the given MonitorKind, returning a typed MonitorRef.
Delegates to Std.Otp.monitor/2.
Return the calling process's own typed pid. Delegates to Std.Otp.self/0.
Remove an existing link between the calling process and pid.
Delegates to Std.Otp.unlink/1.
Functions
fn demonitor(ref: MonitorRef) -> Effect(Unit)
Remove a monitor and flush any pending DOWN message for ref.
Delegates to Std.Otp.demonitor/1.
fn is_alive(m: Type, r: Type, k: Type, pid: RawPid(m, r, k)) -> Effect(Bool)
Report whether the local process pid is currently alive.
Delegates to Std.Otp.is_alive/1.
fn link(m: Type, r: Type, k: Type, pid: RawPid(m, r, k)) -> Effect(Unit)
Establish a bidirectional link between the calling process and pid.
Delegates to Std.Otp.link/1.
fn monitor(m: Type, r: Type, k: Type, kind: MonitorKind, pid: RawPid(m, r, k)) -> Effect(MonitorRef)
Start monitoring pid with the given MonitorKind, returning a typed MonitorRef.
Delegates to Std.Otp.monitor/2.
fn self(m: Type) -> Effect(Pid(m))
Return the calling process's own typed pid. Delegates to Std.Otp.self/0.
fn unlink(m: Type, r: Type, k: Type, pid: RawPid(m, r, k)) -> Effect(Unit)
Remove an existing link between the calling process and pid.
Delegates to Std.Otp.unlink/1.