schema compile REVERT disabled leafref targets error
Even if the leafref is required-instance false,
this situation means that the set of if-features
of the leafref and its target is not the same,
which violates the specs.
diff --git a/src/schema_compile.c b/src/schema_compile.c
index 600646e..58d458a 100644
--- a/src/schema_compile.c
+++ b/src/schema_compile.c
@@ -1523,11 +1523,6 @@
v = 0;
while ((lref = lys_type_leafref_next(l->node, &v))) {
- if (!lref->require_instance) {
- /* the target may be disabled without consequences */
- continue;
- }
-
ret = ly_path_compile_leafref(cctx.ctx, l->node, NULL, lref->path,
(l->node->flags & LYS_IS_OUTPUT) ? LY_PATH_OPER_OUTPUT : LY_PATH_OPER_INPUT, LY_PATH_TARGET_MANY,
LY_VALUE_SCHEMA_RESOLVED, lref->prefixes, &path);