New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 721339 link

Starred by 1 user

Issue metadata

Status: Assigned
Owner:
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: iOS
Pri: 3
Type: Task



Sign in to add a comment

Observer properties should be "weak" (as opposed to "assign").

Project Member Reported by jif@chromium.org, May 11 2017

Issue description

ObservableBoolean should have a weak reference to its observer.

This is to prevent |observer| from ever being a dangling pointer, thus making our code less crash-prone.

In addition this would allow us to remove nearly all occurrences of "setObserver:nil" in the codebase, and thus remove a bunch of deallocs.


 

Comment 1 by jif@chromium.org, May 11 2017

Summary: Observer properties should be "weak" (as opposed to "assign"). (was: Observer properties should be "weak", not instead of "assign".)

Comment 2 by pkl@chromium.org, May 11 2017

Cc: pkl@chromium.org
Components: Internals
Components: -Internals UI>Settings
Labels: -Type-Bug Type-Task
ObservableBoolean is from settings code
Components: UI>Browser>Mobile>Settings

Sign in to add a comment