diff --git a/lib/stdlib/doc/src/gen_server.xml b/lib/stdlib/doc/src/gen_server.xml
index 99b8690b0ac5..8ca39288f390 100644
--- a/lib/stdlib/doc/src/gen_server.xml
+++ b/lib/stdlib/doc/src/gen_server.xml
@@ -298,7 +298,7 @@ gen_server:abcast -----> Module:handle_cast/2
start_link/3,4.
- {hibernate_after,HibernateAfterTimeout}
+ {hibernate_after,HibernateAfterTimeout}
-
Specifies that the gen_server process awaits
@@ -309,10 +309,10 @@ gen_server:abcast -----> Module:handle_cast/2
proc_lib:hibernate/3).
- {debug,Dbgs}
+ {debug,Dbgs}
-
- For every entry in Dbgs,
+ For every entry in Dbgs,
the corresponding function in
sys(3) is called.
diff --git a/lib/stdlib/doc/src/gen_statem.xml b/lib/stdlib/doc/src/gen_statem.xml
index 319fafee07d2..9d290abfa070 100644
--- a/lib/stdlib/doc/src/gen_statem.xml
+++ b/lib/stdlib/doc/src/gen_statem.xml
@@ -626,7 +626,7 @@ handle_event(_, _, State, Data) ->
debug
-
- For every entry in Dbgs,
+ For every entry in Dbgs,
the corresponding function in
sys is called.
diff --git a/lib/stdlib/src/gen_server.erl b/lib/stdlib/src/gen_server.erl
index b57481e95656..f3dab4ec79e0 100644
--- a/lib/stdlib/src/gen_server.erl
+++ b/lib/stdlib/src/gen_server.erl
@@ -257,9 +257,7 @@
proc_lib:option() | enter_loop_opt().
%%
% Some gen:option()s works for enter_loop/*
--type enter_loop_opt() ::
- {'hibernate_after', HibernateAfterTimeout :: timeout()}
- | {'debug', Dbgs :: [sys:debug_option()]}.
+-type enter_loop_opt() :: proc_lib:enter_loop_opt().
-type start_ret() :: % gen:start_ret() without monitor return
{'ok', Pid :: pid()}
diff --git a/lib/stdlib/src/gen_statem.erl b/lib/stdlib/src/gen_statem.erl
index edefcd9e32ec..c5c116b146c9 100644
--- a/lib/stdlib/src/gen_statem.erl
+++ b/lib/stdlib/src/gen_statem.erl
@@ -525,9 +525,8 @@ event_type(Type) ->
% What gen:call/3,4 and gen:stop/1,3 accepts
-type server_ref() :: proc_lib:sup_ref().
--type enter_loop_opt() :: % Some gen:option()s works for enter_loop/*
- {'hibernate_after', HibernateAfterTimeout :: timeout()}
- | {'debug', Dbgs :: [sys:debug_option()]}.
+% Some gen:option()s works for enter_loop/*
+-type enter_loop_opt() :: proc_lib:enter_loop_opt().
-type start_opt() :: proc_lib:option() | enter_loop_opt().
diff --git a/lib/stdlib/src/proc_lib.erl b/lib/stdlib/src/proc_lib.erl
index d7a586347db8..cb2a0938dc48 100644
--- a/lib/stdlib/src/proc_lib.erl
+++ b/lib/stdlib/src/proc_lib.erl
@@ -43,7 +43,7 @@
-export_type([spawn_option/0]).
-export_type([start_spawn_option/0]).
--export_type([sup_name/0, sup_ref/0, option/0, debug/0]).
+-export_type([sup_name/0, sup_ref/0, option/0, debug/0, enter_loop_opt/0]).
-include("logger.hrl").
@@ -98,8 +98,10 @@
-type option() :: {'timeout', Timeout :: timeout()}
| {'debug', Dbgs :: [debug()]}
- | {'spawn_opt', SpawnOptions :: [start_spawn_option()]}
- | {'hibernate_after', HibernateAfterTimeout :: timeout()}.
+ | enter_loop_opt().
+
+-type enter_loop_opt() :: {'hibernate_after', HibernateAfterTimeout :: timeout()}
+ | {'debug', Dbgs :: [sys:debug_option()]}.
-type debug () :: 'trace' | 'log' | 'statistics' | 'debug'