Skip to content
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][dataflow] Remove declToLocConsistent() assertion. #69819

Merged
merged 1 commit into from
Oct 24, 2023

Commits on Oct 23, 2023

  1. [clang][dataflow] Remove declToLocConsistent() assertion.

    As described [here](https://discourse.llvm.org/t/70086/6), there are legitimate
    non-bug scenarios where two `DeclToLoc` maps to be joined contain different
    storage locations for the same declaration. This patch also adds a test
    containing an example of such a situation. (The test fails without the other
    changes in this patch.)
    
    With the assertion removed, the existing logic in `intersectDenseMaps()` will
    remove the corresponding declaration from the joined DeclToLoc map.
    
    We also remove `removeDecl()`'s precondition (that the declaration must be
    associated with a storage location) because this may no longer hold if the
    declaration was previously removed during a join, as described above.
    martinboehme committed Oct 23, 2023
    Configuration menu
    Copy the full SHA
    4d25701 View commit details
    Browse the repository at this point in the history