File 0141-Add-group-metadata-to-EEP48.patch of Package erlang

From d3b8b15a470e68e4690d68cc42ca0b7f757f37da Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Jos=C3=A9=20Valim?= <jose.valim@dashbit.co>
Date: Thu, 12 Dec 2024 11:56:20 +0100
Subject: [PATCH] Add group metadata to EEP48

Also changed one item to keep order alphabetical.
---
 lib/kernel/doc/guides/eep48_chapter.md       | 11 ++++++++---
 system/doc/reference_manual/documentation.md |  3 +++
 2 files changed, 11 insertions(+), 3 deletions(-)

diff --git a/lib/kernel/doc/guides/eep48_chapter.md b/lib/kernel/doc/guides/eep48_chapter.md
index 2f0704e666..8036cd3d9e 100644
--- a/lib/kernel/doc/guides/eep48_chapter.md
+++ b/lib/kernel/doc/guides/eep48_chapter.md
@@ -145,15 +145,20 @@ information to each entry. This EEP documents the following metadata keys:
   deprecated with a binary that represents the reason for deprecation and a
   recommendation to replace the deprecated code.
 
+- **`group := binary()`** - when present, it allows tooling, such as shell
+  autocompletion and documentation generators, to list all entries within the
+  same group together, often using the group name as an indicator. It currently
+  only applies to doc entries, not for module metadata.
+
 - **`since := binary()`** - a binary representing the version such entry was
   added, such as `<<"1.3.0">>` or `<<"20.0">>`.
 
-- **`source_path := binary()`** - the absolute location of the source file for
-  this module. Applies only to the module metadata.
-
 - **`source_annos := [erl_anno:anno()]`** - a list of source code locations.
   You may either store one for each clause or only for the first clause.
 
+- **`source_path := binary()`** - the absolute location of the source file for
+  this module. Applies only to the module metadata.
+
 Any key may be added to Metadata at any time. Keys that are frequently used by
 the community can be standardized in future versions.
 
diff --git a/system/doc/reference_manual/documentation.md b/system/doc/reference_manual/documentation.md
index 9028428ecb..2650df0202 100644
--- a/system/doc/reference_manual/documentation.md
+++ b/system/doc/reference_manual/documentation.md
@@ -206,6 +206,9 @@ There are four reserved metadata keys for `-doc`:
   explaining that it is deprecated and what to use instead. The compiler will
   automatically insert this key if there is a `-deprecated` attribute marking a
   function as deprecated.
+- `group => unicode:chardata()` - A group that the function, type or callback belongs to.
+  It allows tooling, such as shell autocompletion and documentation generators, to list all
+  entries within the same group together, often using the group name as an indicator.
 - `equiv => unicode:chardata() | F/A | F(...)` - Notes that this function is equivalent to
   another function in this module. The equivalence can be described using either
   `Func/Arity`, `Func(Args)` or a [unicode string](`t:unicode:chardata/0`). For example:
-- 
2.43.0

openSUSE Build Service is sponsored by