-
Notifications
You must be signed in to change notification settings - Fork 12.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[clang] Segfault with -module-file-info
#98365
Comments
@llvm/issue-subscribers-clang-modules Author: Dmitriy Chestnykh (chestnykh)
If clang is invoked with `-module-file-info` and the file is of incorrect type then clang segfaults.
There is assert in the code CC: @AaronBallman @cor3ntin @Endilll |
Seems like we should provide a diagnostic instead of crashing. CC @ChuanqiXu9 |
Yeah, it will be better to use a diagnostic than crashing here. The reason why it is left so long is that I thought the tool is majorly used by developers not end users. But we provide it after all. And I feel this issue is suit for beginners since beyond the background, it simply requires us to add a diagnostic for it. |
Hi! This issue may be a good introductory issue for people new to working on LLVM. If you would like to work on this issue, your first steps are:
If you have any further questions about this issue, don't hesitate to ask via a comment in the thread below. |
@llvm/issue-subscribers-good-first-issue Author: Dmitriy Chestnykh (chestnykh)
If clang is invoked with `-module-file-info` and the file is of incorrect type then clang segfaults.
There is assert in the code CC: @AaronBallman @cor3ntin @Endilll |
Okay, I will work on this issue. Assign please it to me |
Currently clang crashes with `-module-file-info` and input file which is not a module Emit error instead of segfaulting. Fix llvm#98365
Currently clang crashes with `-module-file-info` and input file which is not a module Emit error instead of segfaulting. Fix llvm#98365
If clang is invoked with
-module-file-info
and the file is of incorrect type then clang segfaults.There is assert in the code
assert(isCurrentFileAST() && "dumping non-AST?");
Segfault occurs in release build (with disabled assertions).
Should this behavior be fixed or left unchanged?
CC: @AaronBallman @cor3ntin @Endilll
The text was updated successfully, but these errors were encountered: