Skip to content

Commit bfdaf3f

Browse files
boydmJosé Valim
authored andcommitted
Update Process.info spec to reflect the possible nil return value (#7977)
The @SPEC for it did not reflect that possible return value - which causes dialyzer to throw errors if you check for that condition. Now the spec allows for a return value of nil. Signed-off-by: José Valim <[email protected]>
1 parent bc26f10 commit bfdaf3f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/elixir/lib/process.ex

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -636,7 +636,7 @@ defmodule Process do
636636
637637
See `:erlang.process_info/1` for more info.
638638
"""
639-
@spec info(pid) :: keyword
639+
@spec info(pid) :: keyword | nil
640640
def info(pid) do
641641
nillify(:erlang.process_info(pid))
642642
end

0 commit comments

Comments
 (0)