Skip to content

Commit 4e840bc

Browse files
authored
Fix Agent timeout docs: non-negative, not greater than zero (#15569)
1 parent 345deb3 commit 4e840bc

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

lib/elixir/lib/agent.ex

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -327,7 +327,7 @@ defmodule Agent do
327327
passing the agent state. The result of the function invocation is
328328
returned from this function.
329329
330-
`timeout` is an integer greater than zero which specifies how many
330+
`timeout` is a non-negative integer which specifies how many
331331
milliseconds are allowed before the agent executes the function and returns
332332
the result value, or the atom `:infinity` to wait indefinitely. If no result
333333
is received within the specified time, the function call fails and the caller
@@ -366,7 +366,7 @@ defmodule Agent do
366366
elements, the first being the value to return (that is, the "get" value)
367367
and the second one being the new state of the agent.
368368
369-
`timeout` is an integer greater than zero which specifies how many
369+
`timeout` is a non-negative integer which specifies how many
370370
milliseconds are allowed before the agent executes the function and returns
371371
the result value, or the atom `:infinity` to wait indefinitely. If no result
372372
is received within the specified time, the function call fails and the caller
@@ -407,7 +407,7 @@ defmodule Agent do
407407
408408
This function always returns `:ok`.
409409
410-
`timeout` is an integer greater than zero which specifies how many
410+
`timeout` is a non-negative integer which specifies how many
411411
milliseconds are allowed before the agent executes the function and returns
412412
the result value, or the atom `:infinity` to wait indefinitely. If no result
413413
is received within the specified time, the function call fails and the caller

0 commit comments

Comments
 (0)