From 64dba30432a60666faafd0fbda349e6741f59601 Mon Sep 17 00:00:00 2001 From: Carsten Bauer Date: Tue, 20 Feb 2024 23:49:35 +0100 Subject: [PATCH] Update README.md --- README.md | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/README.md b/README.md index e737dce..bea1e60 100644 --- a/README.md +++ b/README.md @@ -30,3 +30,13 @@ julia> t = StableTasks.@spawnat 4 Threads.threadid(); julia> @inferred fetch(t) 4 ``` + +For convenience, and similar to at Distributed.jl, there are also `@fetch` and `@fetchfrom` macros: + +```julia +julia> StableTasks.@fetch 3+3 +6 + +julia> StableTasks.@fetchfrom 2 Threads.threadid() +2 +```