[Bug][move-compiler-v2] re-check dependencies in move-prover paths to compiler #13392
Labels
bug
Something isn't working
compiler-v2
stale-exempt
Prevents issues from being automatically marked and closed as stale
🐛 Bug
TLDR: If we see strange redundant source file problems, they may result from a conflict between .mv and .move files in compiled packages, since there is still a wild search for .mv files in the parser code (which is shared).
--
We should clean/document up the different kinds of compiler/prover inputs, and name them consistently across prover, move-model, compiler-v2, and compiler-v1. This complication results from the various test frameworks and code paths used.
At a high level, we have:
After my last "cleanup", things are almost there, but we still have a few potential problems:
The challenge is that: if there is a .mv file under a directory included in
deps
, then an interface file will be generated, and might conflict with an existing .move source file if the deps points to a package directory. It may be that deps will be handled correctly. There is code in parser/mod.rs that seem so try to make sure this doesn't happen, but it's possible it doesn't always work.For some more details:
The move-model now takes 3 parameters representing move inputs:
Calling the parser (V1 front end,
Compiler::from_package_paths
) these are passed and stored as fields:The parser is run by calling
Compiler: run()
, whichgenerate_interface_files_for_deps(deps, ...)
, which.mv
files indeps
and creates.move
files for them.move
files todeps
parse_program(... targets, deps)
deps
Finally, the parser returns a list of the files parsed, their contents, and the parser output.
For move-prover, move-model, and compiler-v2, the move-model then compares this list with its original lists to decide whether to treat something as
This code is kind of hairy, and also may hide some bugs.
The text was updated successfully, but these errors were encountered: