- if _n_id == old_child then
- if new_child != null then
- new_child.parent = self
- assert new_child isa TId
- _n_id = new_child
- else
- abort
+ for i in [0.._n_ids.length[ do
+ if _n_ids[i] == old_child then
+ if new_child != null then
+ assert new_child isa TId
+ _n_ids[i] = new_child
+ new_child.parent = self
+ else
+ _n_ids.remove_at(i)
+ end
+ return