From f30da506a0827a3e698697692abe168174e0ad6d Mon Sep 17 00:00:00 2001 From: Kerin Millar Date: Tue, 4 Jun 2024 00:30:38 +0100 Subject: Add the GENFUN_API_LEVEL variable declaration This allows for simple API capability checks to be performed by users of the library. It might also obsolete the RC_GOT_FUNCTIONS variable. Signed-off-by: Kerin Millar --- functions.sh | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/functions.sh b/functions.sh index e849541..a0315f9 100644 --- a/functions.sh +++ b/functions.sh @@ -970,6 +970,11 @@ _warn_for_args() # shellcheck disable=2034 RC_GOT_FUNCTIONS=yes +# This shall be incremented by one upon any change being made to the public API. +# It was introduced by gentoo-functions-1.7 with an initial value of 1. +# shellcheck disable=2034 +GENFUN_API_LEVEL=1 + # Assign the LF ('\n') character for later expansion. POSIX Issue 8 permits # $'\n' but it may take years for it to be commonly implemented. genfun_newline=' -- cgit v1.2.3-65-gdbad