Skip to content

Commit

Permalink
Improve Supervisor.start_link/2 spec
Browse files Browse the repository at this point in the history
  • Loading branch information
fishcakez committed Sep 3, 2015
1 parent 3d71754 commit bf36c9d
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/elixir/lib/supervisor.ex
Original file line number Diff line number Diff line change
Expand Up @@ -265,7 +265,7 @@ defmodule Supervisor do
and will exit not only on crashes but also if the parent process
exits with `:normal` reason.
"""
@spec start_link([tuple], options) :: on_start
@spec start_link([Supervisor.Spec.spec], options) :: on_start
def start_link(children, options) when is_list(children) do
spec = Supervisor.Spec.supervise(children, options)
start_link(Supervisor.Default, spec, options)
Expand All @@ -291,6 +291,7 @@ defmodule Supervisor do
Other failure conditions are specified in `start_link/2` docs.
"""
@spec start_link(module, term) :: on_start
@spec start_link(module, term, options) :: on_start
def start_link(module, arg, options \\ []) when is_list(options) do
case Keyword.get(options, :name) do
Expand Down

0 comments on commit bf36c9d

Please sign in to comment.