prusti-dev icon indicating copy to clipboard operation
prusti-dev copied to clipboard

Implement normalization of position ids in the server

Open fpoli opened this issue 3 years ago • 1 comments

@JonasAlaif This PR implements the second normalization described in https://github.com/viperproject/prusti-dev/pull/971#issuecomment-1146060967. A lot of the new code is boilerplate to visit all positions of a program.

Unfortunately, the Program that is seen by the server is an enum of legacy::Program and low::Program, which makes the code a bit messy. The normalization is implemented only for the legacy::Program case, but the same logic can also be implemented for low::Program.

The naming of the various mut/fallible walker/visitor/folder passes is not always consistent. I think we should refactor them in the future to only have visitor, visitor_mut, fallible_mut_visitor, removing the "walker".

fpoli avatar Jun 09 '22 15:06 fpoli

@JonasAlaif feel free to do whatever you want with this PR :)

fpoli avatar Jun 10 '22 17:06 fpoli

I'm going to say that these inefficiencies are all pretty small and also in legacy so it's ok

JonasAlaif avatar Sep 01 '22 14:09 JonasAlaif

bors r+

JonasAlaif avatar Sep 01 '22 14:09 JonasAlaif