diff options
author | George Rimar <grimar@accesssoftek.com> | 2019-09-09 09:43:03 +0000 |
---|---|---|
committer | George Rimar <grimar@accesssoftek.com> | 2019-09-09 09:43:03 +0000 |
commit | 3212ecfea8ca60dc0046b10da9e456e512ccea84 (patch) | |
tree | ea6746c48bad7a0dbef4253f1816ac8d25eddef7 /llvm/lib/CodeGen/DFAPacketizer.cpp | |
parent | d5588293a8c8093e0014229401e541edc7acf5d5 (diff) | |
download | llvm-3212ecfea8ca60dc0046b10da9e456e512ccea84.zip llvm-3212ecfea8ca60dc0046b10da9e456e512ccea84.tar.gz llvm-3212ecfea8ca60dc0046b10da9e456e512ccea84.tar.bz2 |
[lib/ObjectYAML] - Improve and cleanup error reporting in ELFState<ELFT> class.
The aim of this patch is to refactor how we handle and report error.
I suggest to use the same approach we use in LLD: delayed error reporting.
For that I introduced 'HasError' flag which triggers when we report an error.
Now we do not exit instantly on any error. The benefits are:
1) There are no more 'exit(1)' calls in the library code.
2) Code was simplified significantly in a few places.
3) It is now possible to print multiple errors instead of only one.
Also, I changed the messages to be lower case and removed a full stop.
Differential revision: https://reviews.llvm.org/D67182
llvm-svn: 371380
Diffstat (limited to 'llvm/lib/CodeGen/DFAPacketizer.cpp')
0 files changed, 0 insertions, 0 deletions