-
Notifications
You must be signed in to change notification settings - Fork 69
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
Sort upstream facts based on package paths #68
Conversation
Codecov Report
@@ Coverage Diff @@
## main #68 +/- ##
==========================================
+ Coverage 89.23% 89.27% +0.03%
==========================================
Files 54 54
Lines 8233 8239 +6
==========================================
+ Hits 7347 7355 +8
+ Misses 728 727 -1
+ Partials 158 157 -1
📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
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, modulo the question asked below.
d745880
to
658582b
Compare
ec3931c
to
f06151d
Compare
658582b
to
c0f0e58
Compare
f06151d
to
314845f
Compare
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!
c0f0e58
to
cec86d2
Compare
314845f
to
36832a1
Compare
cec86d2
to
830bd2b
Compare
36832a1
to
58fe1b5
Compare
830bd2b
to
dc0e5a7
Compare
58fe1b5
to
3ebe927
Compare
dc0e5a7
to
3782547
Compare
3ebe927
to
73181c5
Compare
This PR fixes two panics due to the assumption that the RHS of the global variable assignments are always variables, which isn't true when RHS is a constant (either defined in the current package, or referenced from upstream package) We also take this opportunity to refactor the code a little bit to be more readable and maintainable. Depends on #68
We are calling
analysis.Pass.AllPackageFacts()
API from the analysis framework to import NilAway facts from upstream dependencies. However, this API is documented asIn some drivers such as nogo, this order is deterministic, however, in most other drives like the one from the
analysis
frameowork, the order will be nondeterministic.Therefore, for determinism in NilAway, this PR sorts imported upstream facts (i.e.,
inference.InferredMap
) based on the package path.Depends on PR #67