   @doc """
   Replace the left child tree of the focus node.
   """
-  @spec set_left(Z.t(), BT.t()) :: Z.t()
+  @spec set_left(Z.t(), BT.t() | nil) :: Z.t()
   def set_left(z, l) do
   end
 
   @doc """
   Replace the right child tree of the focus node.
   """
-  @spec set_right(Z.t(), BT.t()) :: Z.t()
+  @spec set_right(Z.t(), BT.t() | nil) :: Z.t()
   def set_right(z, r) do
   end
 end

end

defmodule Zipper do
  @doc """
  Get a zipper focused on the root node.
  """

  @doc """
  Get the parent of the focus node, if any.
  """
  @spec up(Z.t()) :: Z.t() | nil
  def up(z) do
  end

