We should change clients of RetainPtr to use the adoptNS function instead of the AdoptNS constructor argument. Then we should get rid of the AdoptNS constructor or make it private.
This is mostly done.
*** This bug has been marked as a duplicate of bug 80222 ***