-
Notifications
You must be signed in to change notification settings - Fork 232
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
Handle _Static_assert gracefully. Closes #276 #277
Conversation
@@ -857,6 +857,13 @@ class TranslateASTVisitor final | |||
abort(); | |||
} | |||
|
|||
bool VisitStaticAssertDecl(StaticAssertDecl *SAD) { | |||
std::vector<void *> childIds = {SAD->getAssertExpr(), SAD->getMessage()}; | |||
auto T = QualType(); // don't care about the type |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does this need to be a separate variable?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
no, but if I just pass QualType()
as the 4th argument how do I communicate that we don't care about this parameter?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Move the comment to that line?
Co-authored-by: ahomescu <ah@immunant.com>
Co-authored-by: ahomescu <ah@immunant.com>
Co-authored-by: ahomescu <ah@immunant.com>
Without this PR, the c2rust transpiler barfs on translation units that use this feature. With it, we emit a warning instead.