diff options
Diffstat (limited to 'system')
-rw-r--r-- | system/doc/reference_manual/typespec.xml | 18 | ||||
-rw-r--r-- | system/doc/top/Makefile | 5 | ||||
-rw-r--r-- | system/doc/top/src/erl_html_tools.erl | 28 | ||||
-rw-r--r-- | system/doc/top/templates/index.html.src | 6 |
4 files changed, 26 insertions, 31 deletions
diff --git a/system/doc/reference_manual/typespec.xml b/system/doc/reference_manual/typespec.xml index 9e26e9058d..f17e5df277 100644 --- a/system/doc/reference_manual/typespec.xml +++ b/system/doc/reference_manual/typespec.xml @@ -142,7 +142,7 @@ PairList :: Pair | Pair, PairList - Pair :: Type := Type %% notes a pair that must be present + Pair :: Type := Type %% denotes a pair that must be present | Type => Type TList :: Type @@ -174,19 +174,13 @@ </p> <p> The general form of maps is <c>#{PairList}</c>. The key types in - <c>PairList</c> are allowed to overlap, and if they do, the leftmost pair - takes precedence. A map value does not belong to this type if contains a key - that is not in <c>PairList</c>. + <c>PairList</c> are allowed to overlap, and if they do, the + leftmost pair takes precedence. A map pair has a key in + <c>PairList</c> if it belongs to this type. </p> <p> - Because it is common to end a map type with <c>any() => any()</c> to denote - that keys that do not belong to any other pair in <c>PairList</c> are - allowed, and may map to any value, the shorthand notation <c>...</c> is - allowed as the last pair of a map type. - </p> - <p> - Notice that the syntactic representation of <c>map()</c> is <c>#{...}</c> - (or <c>#{_ => _}</c>, or <c>#{any() => any()}</c>), not <c>#{}</c>. + Notice that the syntactic representation of <c>map()</c> is + <c>#{any() => any()}</c> (or <c>#{_ => _}</c>), not <c>#{}</c>. The notation <c>#{}</c> specifies the singleton type for the empty map. </p> <p> diff --git a/system/doc/top/Makefile b/system/doc/top/Makefile index 6aa9d8d340..7f9cec540b 100644 --- a/system/doc/top/Makefile +++ b/system/doc/top/Makefile @@ -121,10 +121,11 @@ $(HTMLDIR)/index.html + $(HTMLDIR)/applications.html: $(INDEX_SCRIPT) $(TEMPLATE # Check if we are building the index from source or an installed release if test "$$RELEASE_ROOT" = "" ; then \ $(ERL) -noshell -pa $(EBIN) -s erl_html_tools top_index src $(ERL_TOP) \ - $(HTMLDIR) $(SYSTEM_VSN) -s erlang halt ;\ + $(HTMLDIR) `cat "$(ERL_TOP)/OTP_VERSION"` -s erlang halt ;\ else \ $(ERL) -noshell -pa $(EBIN) -s erl_html_tools top_index rel $(RELEASE_ROOT) \ - $(HTMLDIR) $(SYSTEM_VSN) -s erlang halt ;\ + $(HTMLDIR) `cat "$(RELEASE_ROOT)/releases/$(SYSTEM_VSN)/OTP_VERSION"` \ + -s erlang halt ;\ fi diff --git a/system/doc/top/src/erl_html_tools.erl b/system/doc/top/src/erl_html_tools.erl index ab58fdf666..d55c2e1164 100644 --- a/system/doc/top/src/erl_html_tools.erl +++ b/system/doc/top/src/erl_html_tools.erl @@ -54,24 +54,24 @@ top_index() -> top_index(src, Value, filename:join(Value, "doc"), RelName) end. -top_index([src, RootDir, DestDir, OtpRel]) - when is_atom(RootDir), is_atom(DestDir), is_atom(OtpRel) -> - top_index(src, atom_to_list(RootDir), atom_to_list(DestDir), atom_to_list(OtpRel)); -top_index([rel, RootDir, DestDir, OtpRel]) - when is_atom(RootDir), is_atom(DestDir), is_atom(OtpRel) -> - top_index(rel, atom_to_list(RootDir), atom_to_list(DestDir), atom_to_list(OtpRel)); +top_index([src, RootDir, DestDir, OtpBaseVsn]) + when is_atom(RootDir), is_atom(DestDir), is_atom(OtpBaseVsn) -> + top_index(src, atom_to_list(RootDir), atom_to_list(DestDir), atom_to_list(OtpBaseVsn)); +top_index([rel, RootDir, DestDir, OtpBaseVsn]) + when is_atom(RootDir), is_atom(DestDir), is_atom(OtpBaseVsn) -> + top_index(rel, atom_to_list(RootDir), atom_to_list(DestDir), atom_to_list(OtpBaseVsn)); top_index(RootDir) when is_atom(RootDir) -> {_,RelName} = init:script_id(), top_index(rel, RootDir, filename:join(RootDir, "doc"), RelName). -top_index(Source, RootDir, DestDir, OtpRel) -> +top_index(Source, RootDir, DestDir, OtpBaseVsn) -> report("****\nRootDir: ~p", [RootDir]), report("****\nDestDir: ~p", [DestDir]), - report("****\nOtpRel: ~p", [OtpRel]), + report("****\nOtpBaseVsn: ~p", [OtpBaseVsn]), - put(otp_release, OtpRel), + put(otp_base_vsn, OtpBaseVsn), Templates = find_templates(["","templates",DestDir]), report("****\nTemplates: ~p", [Templates]), @@ -81,9 +81,9 @@ top_index(Source, RootDir, DestDir, OtpRel) -> report("****\nGroups: ~p", [Groups]), process_templates(Templates, DestDir, Groups). -top_index_silent(RootDir, DestDir, OtpRel) -> +top_index_silent(RootDir, DestDir, OtpBaseVsn) -> put(silent,true), - Result = top_index(rel, RootDir, DestDir, OtpRel), + Result = top_index(rel, RootDir, DestDir, OtpBaseVsn), erase(silent), Result. @@ -361,7 +361,7 @@ subst_template_1(Group, Stream, Info) -> case file:read(Stream, 100000) of {ok, Template} -> Fun = fun(Match, _) -> {subst(Match, Info, Group),Info} end, - gsub(Template, "#[A-Za-z0-9]+#", Fun, Info); + gsub(Template, "#[A-Za-z_0-9]+#", Fun, Info); {error, Reason} -> {error, Reason} end. @@ -379,8 +379,8 @@ get_version(Info) -> "" end. -subst("#release#", _Info, _Group) -> - get(otp_release); +subst("#otp_base_vsn#", _Info, _Group) -> + get(otp_base_vsn); subst("#version#", Info, _Group) -> get_version(Info); subst("#copyright#", _Info, _Group) -> diff --git a/system/doc/top/templates/index.html.src b/system/doc/top/templates/index.html.src index 9637685946..2ece44b15f 100644 --- a/system/doc/top/templates/index.html.src +++ b/system/doc/top/templates/index.html.src @@ -22,7 +22,7 @@ limitations under the License. <html> <head> <link rel="stylesheet" href="otp_doc.css" type="text/css"/> - <title>Erlang/OTP #release#</title> + <title>Erlang/OTP #otp_base_vsn#</title> <script id="js" type="text/javascript" language="JavaScript" src="js/flipmenu/flipmenu.js"> @@ -36,7 +36,7 @@ limitations under the License. <div id="leftnav"> <div class="innertube"> <img alt="Erlang logo" src="erlang-logo.png"/ > -<!-- small><a href="glossary.html">Glossary</a> |--> +<p/> <small><a href="applications.html">Applications</a><br> <a href="man_index.html">Modules</a></small> <p/> @@ -74,7 +74,7 @@ limitations under the License. <div id="content"> <div class="innertube"> <center> -<font size="+1"><b>Erlang/OTP #release#</b></font><br> +<font size="+1"><b>Erlang/OTP #otp_base_vsn#</b></font><br> </center> <center> <p> |