Skip to content

Commit 019e6b8

Browse files
mgwidmannJosé Valim
authored andcommitted
Correct documentation referencing System.schedulers_online/1 to System.schedulers_online/0 (#5568)
Signed-off-by: José Valim <[email protected]>
1 parent 097fe87 commit 019e6b8

File tree

2 files changed

+6
-4
lines changed

2 files changed

+6
-4
lines changed

lib/elixir/lib/task.ex

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -297,7 +297,7 @@ defmodule Task do
297297
are emitted in the same order as the original `enumerable`.
298298
299299
The level of concurrency can be controlled via the `:max_concurrency`
300-
option and defaults to `System.schedulers_online/1`. The timeout
300+
option and defaults to `System.schedulers_online/0`. The timeout
301301
can also be given as option and defaults to 5000 and it defaults to
302302
the maximum amount of time to wait without a task reply.
303303
@@ -309,9 +309,10 @@ defmodule Task do
309309
## Options
310310
311311
* `:max_concurrency` - sets the maximum number of tasks to run
312-
at the same time. Defaults to `System.schedulers_online/1`.
312+
at the same time. Defaults to `System.schedulers_online/0`.
313313
* `:timeout` - the maximum amount of time to wait without
314314
receiving a task reply (across all running tasks).
315+
Defaults to `5000`.
315316
316317
## Example
317318

lib/elixir/lib/task/supervisor.ex

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ defmodule Task.Supervisor do
122122
are emitted in the same order as the original `enumerable`.
123123
124124
The level of concurrency can be controlled via the `:max_concurrency`
125-
option and defaults to `System.schedulers_online/1`. The timeout
125+
option and defaults to `System.schedulers_online/0`. The timeout
126126
can also be given as option and defaults to 5000 and it defaults to
127127
the maximum amount of time to wait without a task reply.
128128
@@ -133,9 +133,10 @@ defmodule Task.Supervisor do
133133
## Options
134134
135135
* `:max_concurrency` - sets the maximum number of tasks to run
136-
at the same time. Defaults to `System.schedulers_online/1`.
136+
at the same time. Defaults to `System.schedulers_online/0`.
137137
* `:timeout` - the maximum amount of time to wait without
138138
receiving a task reply (across all running tasks).
139+
Defaults to `5000`.
139140
140141
## Examples
141142

0 commit comments

Comments
 (0)