libyang REFACTOR major logging updates
Structured error information instead of a
single error message.
diff --git a/src/parser_internal.h b/src/parser_internal.h
index 92412e2..0c026a0 100644
--- a/src/parser_internal.h
+++ b/src/parser_internal.h
@@ -38,8 +38,9 @@
#define LY_DPARSER_ERR_GOTO(r, err_cmd, lydctx, label) \
if (r) { \
err_cmd; \
+ const struct ly_err_item *__eitem = ly_err_last(((struct lyd_ctx *)lydctx)->data_ctx->ctx); \
if ((r != LY_EVALID) || !lydctx || !(lydctx->val_opts & LYD_VALIDATE_MULTI_ERROR) || \
- (ly_vecode(((struct lyd_ctx *)lydctx)->data_ctx->ctx) == LYVE_SYNTAX)) { \
+ (__eitem->vecode == LYVE_SYNTAX)) { \
goto label; \
} \
}