@@ -202,17 +202,20 @@ struct ly_ctx;
202202 'require-instance false;'. It also enables usage of
203203 [lyd_leafref_get_links](@ref lyd_leafref_get_links) and
204204 [lyd_leafref_link_node_tree](@ref lyd_leafref_link_node_tree) APIs. */
205- #define LY_CTX_BUILTIN_PLUGINS_ONLY 0x0800 /**< By default, context uses all available plugins for types and extensions,
206- both included and external. This options prevents all included plugins to be
207- loaded except for built-in YANG types so all derived types will use these and
208- for all purposes behave as the base type. The option can be used for cases when
209- invalid data needs to be stored in YANG node values. */
205+ #define LY_CTX_BUILTIN_PLUGINS_ONLY 0x0800 /**< Limits the context to use only built-in YANG type plugins,
206+ treating all derived types as their base type.
207+ Useful for storing invalid data in YANG node values.
208+ This option has a global effect: the global plugin array is initialized only when no contexts exist.
209+ If any context was created without this flag and is still alive,
210+ creating a new context with this flag will not have the intended effect. */
211+
210212#define LY_CTX_LYB_HASHES 0x1000 /**< Generate hashes for all the schema nodes. Required when using LYB data parse
211213 or print. */
212- #define LY_CTX_STATIC_PLUGINS_ONLY 0x2000 /**< By default, external plugins from directories the path to which is obtained
213- from the `LIBYANG_TYPES_PLUGINS_DIR` and `LIBYANG_EXTENSIONS_PLUGINS_DIR` environmental variables
214- are loaded. This option prevents loading of all external plugins and only
215- the static (libyang built-in) plugins are loaded. */
214+ #define LY_CTX_STATIC_PLUGINS_ONLY 0x2000 /**< Restricts the context to load only static (built-in) plugins,
215+ ignoring external plugins from directories specified by `LIBYANG_TYPES_PLUGINS_DIR` and
216+ `LIBYANG_EXTENSIONS_PLUGINS_DIR`. This option has a global effect: the global plugin array
217+ is initialized only when no contexts exist. If any context was created without this flag
218+ and is still alive, creating a new context with this flag will not have the intended effect. */
216219
217220/* 0x80000000 reserved for internal use */
218221
0 commit comments