Skip to content

Commit 9395bb1

Browse files
author
Thomaz Leite
committed
Define IEx.dont_display_result in IO.ANSI.Docs
This removes all remaining references to IEx from IO.ANSI.Docs and makes the dont_display_result function more generic by replacing the "in iex" bit with "in output".
1 parent 47feb1b commit 9395bb1

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

lib/elixir/lib/io/ansi/docs.ex

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ defmodule IO.ANSI.Docs do
4343
else
4444
IO.puts "* #{string}\n"
4545
end
46-
IEx.dont_display_result
46+
dont_display_result
4747
end
4848

4949
defp write_doc_heading(heading, colors) do
@@ -68,9 +68,11 @@ defmodule IO.ANSI.Docs do
6868
else
6969
IO.puts doc
7070
end
71-
IEx.dont_display_result
71+
dont_display_result
7272
end
7373

74+
defp dont_display_result, do: :"do not show this result in output"
75+
7476
defp process([], _indent, _colors), do: nil
7577

7678
defp process(["# " <> heading | rest], _indent, colors) do

lib/iex/lib/iex.ex

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -343,7 +343,7 @@ defmodule IEx do
343343
end
344344

345345
@doc false
346-
def dont_display_result, do: :"do not show this result in iex"
346+
def dont_display_result, do: :"do not show this result in output"
347347

348348
## Helpers
349349

0 commit comments

Comments
 (0)