.weakref

Alexandre Oliva oliva@gnu.org
Tue Jun 23 06:40:46 GMT 2020


On Jun 12, 2020, Fangrui Song <i@maskray.me> wrote:

> On 2020-06-11, Alexandre Oliva wrote:
>> On Jun 11, 2020, Fangrui Song <i@maskray.me> wrote:

>>> What features can a dedicated .weakref express while an ordinary .weak
>>> reference can't?

>> https://web.archive.org/web/2/people.redhat.com/aoliva/writeups/weakref/weakref.txt

> Thanks for the write-up! A comment regarding this sentence:

>> which has the effect that any references to the symbol in the user's
>> code will also be regarded as weak.  This has two negative side
>> effects:

> Can the compiler emit `.weak` lazily?

It can, as it does in the compiler-internal implementation of weakref.
But making weak mean that would change the meaning of weak.

-- 
Alexandre Oliva, freedom fighter    he/him    https://FSFLA.org/blogs/lxo/
Free Software Evangelist              Stallman was right, but he's left :(
GNU Toolchain Engineer           Live long and free, and prosper ethically


More information about the Binutils mailing list