File 1331-Fix-typos-in-lib-erl_docgen.patch of Package erlang
From a702850e6e6b8e40904cf358798ae51b92f7a574 Mon Sep 17 00:00:00 2001
From: "Kian-Meng, Ang" <kianmeng@cpan.org>
Date: Mon, 13 Dec 2021 09:05:41 +0800
Subject: [PATCH] Fix typos in lib/erl_docgen
---
lib/erl_docgen/doc/src/doc_storage.xml | 2 +-
lib/erl_docgen/priv/bin/github_link.escript | 2 +-
lib/erl_docgen/priv/xsl/db_html.xsl | 2 +-
lib/erl_docgen/src/docgen_edoc_xml_cb.erl | 6 +++---
lib/erl_docgen/src/docgen_otp_specs.erl | 2 +-
5 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/lib/erl_docgen/priv/xsl/db_html.xsl b/lib/erl_docgen/priv/xsl/db_html.xsl
index 33d6773a7b..971f9dcf84 100644
--- a/lib/erl_docgen/priv/xsl/db_html.xsl
+++ b/lib/erl_docgen/priv/xsl/db_html.xsl
@@ -752,7 +752,7 @@
<xsl:template match="marker" mode="local_type">
<xsl:param name="local_types"/>
<xsl:param name="global_types"/>
- <!-- Craete no anchor -->
+ <!-- Create no anchor -->
<!-- It would be possible to create a link to the global type
(if there is one), but that would mean even more code...
-->
diff --git a/lib/erl_docgen/src/docgen_edoc_xml_cb.erl b/lib/erl_docgen/src/docgen_edoc_xml_cb.erl
index d5511eae9d..4590926fad 100644
--- a/lib/erl_docgen/src/docgen_edoc_xml_cb.erl
+++ b/lib/erl_docgen/src/docgen_edoc_xml_cb.erl
@@ -185,7 +185,7 @@ chapter_title(#xmlElement{content=Es}) -> % name = h3 | h4
%% Es1 = Es2 = [#xmlElement{} | #xmlText{}]
%% Fix things that are allowed in XHTML but not in chapter/erlref DTDs.
%% 1) lists (<ul>, <ol>, <dl>) and code snippets (<pre>) can not occur
-%% within a <p>, such a <p> must be splitted into a sequence of <p>,
+%% within a <p>, such a <p> must be split into a sequence of <p>,
%% <ul>, <ol>, <dl> and <pre>.
%% 2) <a> must only have either a href attribute (corresponds to a
%% <seealso> or <url> in the XML code) in which case its content
@@ -282,7 +282,7 @@ otp_xmlify_es([E | Es]) ->
otp_xmlify_e(E) ++ otp_xmlify_es(Es);
%% paragraph contained dl, ul and/or pre and has been
- %% splitted
+ %% split
SubEs ->
lists:flatmap(fun otp_xmlify_e/1, SubEs) ++
otp_xmlify_es(Es)
@@ -452,7 +452,7 @@ otp_xmlify_e(E) ->
%%--Tags with special handling------------------------------------------
%% otp_xmlify_a(A1) -> [A2]
-%% Takes an <a> element and filters the attributes to decide wheather
+%% Takes an <a> element and filters the attributes to decide whether
%% its a seealso/url or a marker.
%% In the case of a seealso/url, the href part is checked, making
%% sure a .xml/.html file extension is removed.
diff --git a/lib/erl_docgen/src/docgen_otp_specs.erl b/lib/erl_docgen/src/docgen_otp_specs.erl
index 396aa2588f..5be8186098 100644
--- a/lib/erl_docgen/src/docgen_otp_specs.erl
+++ b/lib/erl_docgen/src/docgen_otp_specs.erl
@@ -164,7 +164,7 @@ collect_localdef(E = #xmlElement{content = Es}, Opts) ->
{Name,N0,format_type(N0, get_elem(type, Es), Opts)}.
%% "A = t(), B = t()" is coalesced into "A = B = t()".
-%% Names as B above are kept, but the formated string is empty.
+%% Names as B above are kept, but the formatted string is empty.
coalesce_local_defs([], _Last) ->
[];
coalesce_local_defs([{Name,N0,TypeS} | L], Last) when Name =:= N0 ->
--
2.31.1