File 0370-erts-Remove-R-from-documentation.patch of Package erlang
From 4ff5be8ddcbf7c4b8028c857b07a628623e02924 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Lukas=20Backstr=C3=B6m?= <lukas@erlang.org>
Date: Wed, 19 Mar 2025 12:32:54 +0100
Subject: [PATCH] erts: Remove +R from documentation
The +R flag has not been used since 2012, so we remove it
from the docs but keep it in the code in case we ever need
to use it again in the future.
---
erts/doc/guides/introduction.md | 9 ---------
erts/doc/references/erl_cmd.md | 19 ++-----------------
erts/doc/src/erlang_system_info.md | 7 -------
erts/etc/common/erlexec.c | 1 -
erts/preloaded/src/erlang.erl | 1 -
5 files changed, 2 insertions(+), 35 deletions(-)
diff --git a/erts/doc/guides/introduction.md b/erts/doc/guides/introduction.md
index c008109cf4..ae5ee4e31d 100644
--- a/erts/doc/guides/introduction.md
+++ b/erts/doc/guides/introduction.md
@@ -24,15 +24,6 @@ limitations under the License.
The Erlang Runtime System Application, ERTS, contains functionality necessary to
run the Erlang system.
-> #### Note {: .info }
->
-> By default, `ERTS` is only guaranteed to be compatible with other Erlang/OTP
-> components from the same release as `ERTS` itself.
->
-> For information on how to communicate with Erlang/OTP components from earlier
-> releases, see the documentation of system flag [`+R`](erl_cmd.md#compat_rel)
-> in [erl](erl_cmd.md).
-
## Prerequisites
It is assumed that the reader is familiar with the Erlang programming language.
diff --git a/erts/doc/references/erl_cmd.md b/erts/doc/references/erl_cmd.md
index a3cccd6c64..d1e5e0aa53 100644
--- a/erts/doc/references/erl_cmd.md
+++ b/erts/doc/references/erl_cmd.md
@@ -65,14 +65,14 @@ arguments_:
_Examples:_
```erlang
-% erl +W w -sname arnie +R 9 -s my_init -extra +bertie
+% erl +W w -sname arnie +S 2 -s my_init -extra +bertie
(arnie@host)1> init:get_argument(sname).
{ok,[["arnie"]]}
(arnie@host)2> init:get_plain_arguments().
["+bertie"]
```
-Here `+W w` and `+R 9` are emulator flags. `-s my_init` is an init flag,
+Here `+W w` and `+S 2` are emulator flags. `-s my_init` is an init flag,
interpreted by `init`. `-sname arnie` is a user flag, stored by `init`. It is
read by Kernel and causes the Erlang runtime system to become distributed.
Finally, everything after `-extra` (that is, `+bertie`) is considered as plain
@@ -856,21 +856,6 @@ behavior of earlier flags.
On Windows the default value is set to `8196` because the normal OS
limitations are set higher than most machines can handle.
-- **`+R ReleaseNumber`{: #compat_rel }** - Sets the compatibility mode.
-
- The distribution mechanism is not backward compatible by default. This flag
- sets the emulator in compatibility mode with an earlier Erlang/OTP release
- `ReleaseNumber`. The release number must be in the range
- `<current release>-2` through `<current release>`. This limits the emulator,
- making it possible for it to communicate with Erlang nodes (as well as C
- and Java nodes) running that earlier release.
-
- > #### Note {: .info }
- >
- > Ensure that all nodes (Erlang-, C-, and Java nodes) of a distributed Erlang
- > system is of the same Erlang/OTP release, or from two different Erlang/OTP
- > releases X and Y, where _all_ Y nodes have compatibility mode X.
-
- **`+r`** - Forces ETS memory blocks to be moved on reallocation.
- **`+rg ReaderGroupsLimit`{: #+rg }** - Limits the number of reader groups used
diff --git a/erts/doc/src/erlang_system_info.md b/erts/doc/src/erlang_system_info.md
index dd52ac8f5a..33cf7ce30c 100644
--- a/erts/doc/src/erlang_system_info.md
+++ b/erts/doc/src/erlang_system_info.md
@@ -70,7 +70,6 @@ order to make it easier to navigate.
- [`System Information`](`m:erlang#system_info/1-system-information`) -
[`c_compiler_used`](`m:erlang#system_info_c_compiler_used`),
[`check_io`](`m:erlang#system_info_check_io`),
- [`compat_rel`](`m:erlang#system_info_compat_rel`),
[`debug_compiled`](`m:erlang#system_info_debug_compiled`),
[`driver_version`](`m:erlang#system_info_driver_version`),
[`dynamic_trace`](`m:erlang#system_info_dynamic_trace`),
@@ -786,12 +785,6 @@ Returns various information about the current system (emulator) as specified by
that the content of the returned list can vary between platforms and over
time. It is only guaranteed that a list is returned.
-- `compat_rel`{: #system_info_compat_rel } - Returns the compatibility mode
- of the local node as an integer. The integer returned represents the
- Erlang/OTP release that the current emulator has been set to be backward
- compatible with. The compatibility mode can be configured at startup by using
- command-line flag [`+R`](erl_cmd.md#compat_rel) in `erl(1)`.
-
- `debug_compiled`{: #system_info_debug_compiled } - Returns `true` if the
emulator has been debug-compiled, otherwise `false`.
diff --git a/erts/etc/common/erlexec.c b/erts/etc/common/erlexec.c
index e8189fb30d..1ebec55df0 100644
--- a/erts/etc/common/erlexec.c
+++ b/erts/etc/common/erlexec.c
@@ -1279,7 +1279,6 @@ usage_aux(void)
"[+C MODE] [+dcg DECENTRALIZED_COUNTER_GROUPS_LIMIT] [+h HEAP_SIZE_OPTION] "
"[+J[Pperf|Msingle] JIT_OPTION] "
"[+M<SUBSWITCH> <ARGUMENT>] [+P MAX_PROCS] [+Q MAX_PORTS] "
- "[+R COMPAT_REL] "
"[+r] [+rg READER_GROUPS_LIMIT] [+s<SUBSWITCH> SCHEDULER_OPTION] "
"[+S NO_SCHEDULERS:NO_SCHEDULERS_ONLINE] "
"[+SP PERCENTAGE_SCHEDULERS:PERCENTAGE_SCHEDULERS_ONLINE] "
diff --git a/erts/preloaded/src/erlang.erl b/erts/preloaded/src/erlang.erl
index 64a84ba9b7..9751b414c4 100644
--- a/erts/preloaded/src/erlang.erl
+++ b/erts/preloaded/src/erlang.erl
@@ -9908,7 +9908,6 @@ the `CpuTopology` type to change.
gcov | valgrind | gprof | lcnt | frmptr;
(c_compiler_used) -> {atom(), term()};
(check_io) -> [_];
- (compat_rel) -> integer();
(cpu_topology) -> CpuTopology when
CpuTopology :: cpu_topology();
({cpu_topology, defined | detected | used}) -> CpuTopology when
--
2.43.0