GNOME Bugzilla – Bug 748334
[RFE][patch] improve orcc reporting
Last modified: 2018-11-03 10:47:50 UTC
Created attachment 302184 [details] patches as tgz I played with orcc some time ago, and hit a crash caused by incorrect input. While debugging my issue, I found the orcc output too terse and not very friendly. So, I took the chance and spent some days hacking the parser sources (orcparse.c). It started with a few hacks, and I ended up rewriting a good part of it: * new richer parsing API * overhauled internal structure with massive modularization and cleanup * richer error reporting * more strict checking * new orcc option to do just the parsing * abort on parsing failed, instead of going ahead blindly and see the bytecode emitter crash This code was rotting on my github account from some time, so I thought it would be of some good here, maybe. Please find attach the resulting 36 patches (yes, thirty-six), made with git format-patch. I intentionally made the small trying to make review easy. Each patch should leave the code working as good practice mandates, but IMHO those are better merged as a whole, if that would be the case. Commit message may be terse, maybe too much. Quite often the patch title self-explanatory, hopefully it actually is so. github repo, for reference: https://github.com/mojaves/orc
patchset stats at glance: $ git log -36 -p | diffstat orc/orcparse.c | 1395 +++++++++++++++++++++++++++++++++---------------------- orc/orcparse.h | 11 orc/orcprogram.c | 90 ++- orc/orcprogram.h | 2 orc/orcutils.c | 31 + orc/orcutils.h | 20 tools/orcc.c | 134 +++-- 7 files changed, 1070 insertions(+), 613 deletions(-)
Thanks!
-- GitLab Migration Automatic Message -- This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity. You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/gstreamer/orc/issues/8.