================
@@ -2579,13 +2579,44 @@ bool CallVirt(InterpState &S, CodePtr OpPC, const 
Function *Func,
                                          OverriderPointeeType))
       return true;
 
-    // We've called Overrider above, but calling code expects us to return what
-    // InitialFunction returned. According to the rules for covariant return
-    // types, what InitialFunction returns needs to be a base class of what
-    // Overrider returns. So, we need to do an upcast here.
+    // See, the base cast from the return value of InitialFunction to that of
+    // Overrider might be ambiguous due to mutliple inheritance. HOWEVER, this
+    // ambiguity can be cleared up by looking at the return values for all the
+    // overriding functions in the base path from InitialFunction to Overrider.
+    // This is all terrible and slow, but if you use this, you get what you
+    // deserve.
----------------
ojhunt wrote:

ahahahah :D

https://github.com/llvm/llvm-project/pull/242381
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to