parser yang BUGFIX allow in/out without substatements
Refs sysrepo/sysrepo#3117
diff --git a/src/parser_yang.c b/src/parser_yang.c
index dd84480..b81cf60 100644
--- a/src/parser_yang.c
+++ b/src/parser_yang.c
@@ -804,7 +804,8 @@
MOVE_INPUT(ctx, 1);
goto extension;
case '{':
- /* allowed only for input and output statements which can be without arguments */
+ case ';':
+ /* allowed only for input and output statements which are without arguments */
if ((*kw == LY_STMT_INPUT) || (*kw == LY_STMT_OUTPUT)) {
break;
}
@@ -2860,11 +2861,6 @@
YANG_READ_SUBSTMT_NEXT_ITER(ctx, kw, word, word_len, inout_p->exts, ret, cleanup);
}
- if (!inout_p->child) {
- LOGVAL_PARSER(ctx, LY_VCODE_MISSTMT, "data-def-stmt", lyplg_ext_stmt2str(inout_kw));
- return LY_EVALID;
- }
-
cleanup:
return ret;
}