[esnacc-dev] [PATCH] Improved error reporting for SEQUENCE tags - added fieldName that caused the error

Charles Wright charles_wright at azimuthsystems.com
Fri Jul 22 00:59:43 UTC 2016


---
 compiler/back-ends/c++-gen/gen-code.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/compiler/back-ends/c++-gen/gen-code.c b/compiler/back-ends/c++-gen/gen-code.c
index 444bc8d..f8a091c 100644
--- a/compiler/back-ends/c++-gen/gen-code.c
+++ b/compiler/back-ends/c++-gen/gen-code.c
@@ -2742,7 +2742,7 @@ PrintCxxSeqDefCode (FILE *src, FILE *hdr, ModuleList *mods, Module *m,
                     }
                     else
                     {
-                        fprintf (src, "      throw EXCEPT(\"SEQUENCE is missing non-optional root elmt\", DECODE_ERROR);\n");
+                        fprintf (src, "      throw EXCEPT(\"SEQUENCE is missing non-optional root elmt (%s)\", DECODE_ERROR);\n", e->fieldName);
                     }
                     fprintf (src, "  }\n\n");
                 }
-- 
1.9.1



More information about the dev mailing list