AaronBallman wrote:

> > > I just noticed there's no documentation for 
> > > `__builtin_virtual_member_address()` so I'm addressing that.
> > > Due to code drift and time I realized that they disagree as to whether 
> > > they should take `C*` or `C&` so I'm going to make them both accept 
> > > either (existing code means we can't unify on one or the other, but also 
> > > there's no real reason to not accept either and simply do the correct 
> > > thing)
> > 
> > 
> > most of our builtins take pointers. Accepting both seems unwise. people 
> > might want to do interesting things in sfinae context and if we accept 
> > everything and anything it will end up causing more pain than it alleviates.
> 
> Hmmm, I'll revert to only supporting pointers in `get_vtable_pointer` but 
> there's existing code dependent on the non-pointer argument to 
> virtual_member_address which makes it difficult to switch to having a pointer 
> argument.

I'm confused -- how is there existing code depending on a builtin which doesn't 
yet exist in Clang? Are we copying these builtins from somewhere else?

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

Reply via email to