-
Notifications
You must be signed in to change notification settings - Fork 122
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
Fix passing pointers as call arguments #763
Conversation
Can you check if this PR fixes #762 by any chance? |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #763 +/- ##
==========================================
+ Coverage 94.70% 94.71% +0.01%
==========================================
Files 49 49
Lines 7322 7342 +20
==========================================
+ Hits 6934 6954 +20
Misses 388 388
|
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.
clang-tidy made some suggestions
That is because of a separate reason, commented on that issue. |
clang-tidy review says "All clean, LGTM! 👍" |
@@ -1536,7 +1551,8 @@ Expr* getArraySizeExpr(const ArrayType* AT, ASTContext& context, | |||
// FIXME: We cannot use GlobalStoreAndRef to store a whole array so now | |||
// arrays are not stored. | |||
StmtDiff argDiffStore; | |||
if (passByRef && !argDiff.getExpr()->getType()->isArrayType()) | |||
if (passByRef && !argDiff.getExpr()->getType()->isArrayType() && |
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.
Can't we use argDiffType
here, too?
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.
It was inside the if condition earlier, but moved it out now 👍🏼
clang-tidy review says "All clean, LGTM! 👍" |
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.
LGTM!
@vaithak Can you please update pull request description / commit message with details how it addresses the issue? Does this pull request addresses pointer arithmetic expressions such as Also, wouldn't this pull request #762 fix the issue as well? |
@parth-07, I did not see your comment before merging. I guess I was too excited about this PR. Apologies! |
For #762, I have commented more about that on the issue itself. Regarding pointer arithmetic, I will test it out and make changes if required along with test cases in a separate PR. |
fixes #735, #636