[Lldb-commits] [lldb] [lldb] Fix and re-enable TestUseSourceCache.py (PR #111237)
Pavel Labath via lldb-commits
lldb-commits at lists.llvm.org
Fri Oct 11 00:36:07 PDT 2024
labath wrote:
> > With this in mind, deleting the file is representative of an editor wanting to save the file using the deletion strategy,...
> > Yes. I had meant it is not representative of what Android Studio (or _some_ editors) does.
>
> > think it's not our goal here to ensure the editor cannot save the file if the setting is true.
>
> I agree that having a test that sets `use_source_cache=true` and expects failure behavior is not a goal. But, it is how we _observe_ that the test input `cpp` source file we use satisfies the condition to use mmap. If the condition to use mmap changes (e.g., from filesize=16K to filesize=32K), then the test input source file will no longer trigger mmap, yet the `use_source_cache=false` test will keep passing. So, I think having that negative test case, despite being weird, still serves some purpose.
Makes sense (and now that I think about it, I think I used some line of reasoning like this on the original patch that introduced this).
https://github.com/llvm/llvm-project/pull/111237
More information about the lldb-commits
mailing list