Re: [PATCH] Use __builtin_addressof in std::addressof

2024-12-18 Thread Jonathan Wakely
On Wed, 18 Dec 2024 at 18:39, François Dumont wrote: > > Hi > > As proposed on another thread here is the patch to make std::__addressof > and std::addressof compile time equivalent. > > Maybe not entirely because of the [[__nodiscard__]] on std::addressof > but still closer. > > libstdc++: H

[PATCH] Use __builtin_addressof in std::addressof

2024-12-18 Thread François Dumont
Hi As proposed on another thread here is the patch to make std::__addressof and std::addressof compile time equivalent. Maybe not entirely because of the [[__nodiscard__]] on std::addressof but still closer.     libstdc++: Have std::addressof use __builtin_addressof     Rather than calling