The parseInputFile function returns an empty unique_ptr to signal an
error, like when the input file doesn't exist, or is malformed. In this
case, the tool should exit immediately rather than segfault by
dereferencing the unique_ptr later.
Details
Details
Diff Detail
Diff Detail
- Repository
- rG LLVM Github Monorepo
Unit Tests
Unit Tests
Event Timeline
Comment Actions
lgtm with the test CHECK change
llvm/test/tools/llvm-reduce/fail-file-open.test | ||
---|---|---|
5 | is this error message cross platform? for example, I see # Don't check the OS-dependent message "No such file or directory". in llvm/test/tools/llvm-objdump/invalid-input.test I think everything up to the error: is good enough. The main thing is that it doesn't crash. |
Comment Actions
do you need help landing this?
I don't have commit access if that's what you mean. Thanks very much for the review, much appreciated!
is this error message cross platform? for example, I see
in llvm/test/tools/llvm-objdump/invalid-input.test
I think everything up to the error: is good enough. The main thing is that it doesn't crash.