timon-ul wrote: Okay so while fixing the newly added test from the recursion on implementations I noticed 2 new things:
1. I do not know if there is an easy way with dealing with multiple instantiations being reported in a test. When we had `Even<42>` in the test it reported back 43 implementations for `Even`, which makes sense, and all these copies are at the same locations, but without manually stacking a lot of `[[]]` I don't know how to deal with this. 2. Technically we are lying with what relations we report, but maybe this is fine. When I put `Even<2>` I would expect `Even` to find itself once, from `Odd<1>` since it inherits from `Even<2>`. But in my test you see I had to report the location of `Even<I-1>` twice. Even worse if I instead put `Odd<1>` I still find `Even<I-1>`, even though there is no instantiation of it. This is because in the case of an instantiation we just additionally report this new relation, but the old recording is kept, this will look at `Odd : Even<I-1>` and add the relation to the `Even<I-1>` template. Now we could say we only report the relation to the instantiation, but that would then imply every time I ask for inheritance on a template itself, I would need to iterate over all its instantiations to get this info since it is lost in the template itself. I guess it boils down to: do we want to report inheritance even if there is no instantiation for this inheritance? https://github.com/llvm/llvm-project/pull/177273 _______________________________________________ cfe-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
