rjmccall wrote:

Having an abstraction for this would be nice. It doesn't *have* to be a base 
class specifically, though; we can do a more extrinsic tagged-union without 
actually unifying the class hierarchies, like `llvm::CallSite` does. Swift has 
a type called `AnyFunctionRef` that unifies several different kinds of entity 
that behave like functions.

I feel like most of the uses of this abstraction would want it to cover blocks, 
though.  Basically a union of every kind of code context.

https://github.com/llvm/llvm-project/pull/115056
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to