# Reassigning a WeakRef's value?

**URL:** <https://discourse.julialang.org/t/reassigning-a-weakrefs-value/140086>\
**Category:** General Usage\
**Tags:** ref, gc\
**Created:** [October 18, 2026, 4:13pm UTC](https://discourse.julialang.org/t/reassigning-a-weakrefs-value/140086 "2026-10-18T16:13:36Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![skraemer](https://avatars.discourse-cdn.com/v4/letter/s/4bbf92/32.png) [@skraemer](https://discourse.julialang.org/u/skraemer)\
**Post date:** [October 18, 2026, 4:13pm UTC](https://discourse.julialang.org/t/reassigning-a-weakrefs-value/140086/1 "2026-10-18T16:13:36Z")

</div>

After creating `w = WeakRef([1])`, is there any problem with reassigning `w.value = [2]`, both before or after its value is cleared to `nothing` by `GC.gc()`?

I can not find anything on this, nor can I observe any unexpected behaviour (so far).

Do you know more?
