We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent d935ebf commit f0db57fCopy full SHA for f0db57f
lib/ex_doc/doc_ast.ex
@@ -85,17 +85,17 @@ defmodule ExDoc.DocAST do
85
case content do
86
# if we already have <pre><code>...</code></pre>, carry on
87
[{:code, _, _}] ->
88
- {:pre, attrs, parse_erl_ast(content), %{}}
+ {:pre, attrs, parse_erl_ast(List.wrap(content)), %{}}
89
90
# otherwise, turn <pre>...</pre> into <pre><code>...</code></pre>
91
_ ->
92
- content = [{:code, [], parse_erl_ast(content), %{}}]
+ content = [{:code, [], parse_erl_ast(List.wrap(content)), %{}}]
93
{:pre, attrs, content, %{}}
94
end
95
96
97
defp parse_erl_ast({tag, attrs, content}) when is_atom(tag) do
98
- {tag, attrs, parse_erl_ast(content), %{}}
+ {tag, attrs, parse_erl_ast(List.wrap(content)), %{}}
99
100
101
@doc """
0 commit comments