     end
   end
 
-  # Get the full signature from a function.
-  defp print_signature({ _info, _line, _kind, _args, false }) do
-    false
-  end
-
-  defp print_signature({ { name, _arity }, _line, kind, args, docs }) do
-    args = Enum.map_join(args, ", ", signature_arg(&1))
-    IO.puts IO.ANSI.escape("%{yellow}* #{kind} #{name}(#{args})")
-    IO.ANSI.escape("%{yellow}#{docs}") || ""
-  end
-
-  defp signature_arg({ ://, _, [left, right] }) do
-    signature_arg(left) <> " // " <> Macro.to_binary(right)
-  end
-
-  defp signature_arg({ var, _, _ }) do
+  defp print_doc({ { fun, _ }, _line, kind, args, doc }) do
+    args = Enum.map_join(args, ", ", print_doc_arg(&1))
+    IO.puts IO.ANSI.escape("%{yellow}* #{kind} #{fun}(#{args})\n")
+    IO.write IO.ANSI.escape("%{yellow}#{doc}")
+  end
+
+  defp print_doc_arg({ ://, _, [left, right] }) do
+    print_doc_arg(left) <> " // " <> Macro.to_binary(right)
+  end
+
+  defp print_doc_arg({ var, _, _ }) do
     atom_to_binary(var)
   end
 

  """
  defmacro h({ :/, _, [{ { :., _, [mod, fun] }, _, [] }, arity] }) do
    quote do
      h(unquote(mod), unquote(fun), unquote(arity))
    end
  end

  defmacro h({ { :., _, [mod, fun] }, _, [] }) do
    quote do
      h(unquote(mod), unquote(fun))
    end
  end

  defmacro h({ :/, _, [{ fun, _, args }, arity] }) when args == [] or is_atom(args) do
    quote do
      h(unquote(fun), unquote(arity))
    end
  end

  defmacro h({ name, _, args }) when args == [] or is_atom(args) do
    quote do
      candidates = [unquote(__MODULE__), Kernel, Kernel.SpecialForms]

      # If we got at least one :ok, final result will be :ok
      Enum.reduce candidates, :not_found, fn(mod, flag) ->
        ret = h(mod, unquote(name))
        if flag == :ok do
          :ok
        else
          ret
        end
      end
    end
  end

  defmacro h(other) do
    quote do
      h(unquote(other), [])
    end
  end

  defmacrop mfa_exported?(module, function, arity) do
    quote do
      function_exported?(unquote(module), unquote(function), unquote(arity)) or
         macro_exported?(unquote(module), unquote(function), unquote(arity))
    end
  end

  defp h_kernel(function, arity) do
    if mfa_exported?(Kernel, function, arity) do
      h(Kernel, function, arity)
    else
      h(Kernel.SpecialForms, function, arity)
    end
  end

  @doc false
  def h(:h, 1) do
    h(__MODULE__, :h, 1)
  end

  def h(function, arity) when is_atom(function) and is_integer(arity) do
    if mfa_exported?(__MODULE__, function, arity) do
      h(__MODULE__, function, arity)
    else
      h_kernel(function, arity)
    end
  end

  def h(module, []) when is_atom(module) do
    case Code.ensure_loaded(module) do
      { :module, _ } ->
        case module.__info__(:moduledoc) do

  Shows the documentation for IEx.Helpers.
  """
  def h() do
    __help__(IEx.Helpers)
  end

  @doc """
