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

Consider indirect mutation during const qualification dataflow #90214

Merged
merged 1 commit into from
Oct 29, 2021

Commits on Oct 26, 2021

  1. Consider indirect mutation during const qualification dataflow

    Previously a local would be qualified if either one of two separate data
    flow computations indicated so. First determined if a local could
    contain the qualif, but ignored any forms of indirect mutation. Second
    determined if a local could be mutably borrowed (and so indirectly
    mutated), but which in turn ignored the qualif.
    
    The end result was incorrect because the effect of indirect mutation was
    effectivelly ignored in the all but the final stage of computation.
    
    In the new implementation the indirect mutation is directly incorporated
    into the qualif data flow. The local variable becomes immediately
    qualified once it is mutably borrowed and borrowed place type can
    contain the qualif.
    
    In general we will now reject additional programs, program that were
    prevously unintentionally accepted.
    
    There are also some cases which are now accepted but were previously
    rejected, because previous implementation didn't consider whether
    borrowed place could have the qualif under the consideration.
    tmiasko committed Oct 26, 2021
    Configuration menu
    Copy the full SHA
    93f85f5 View commit details
    Browse the repository at this point in the history