Closed Bug 1095541 Opened 10 years ago Closed 10 years ago

break nsRefPtr.h's dependence on nsCOMPtr.h

Categories

(Core :: XPCOM, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla36

People

(Reporter: froydnj, Assigned: froydnj)

Details

Attachments

(3 files)

Breaking the dependence requires doing two things:

1. Moving already_AddRefed to some common place that nsCOMPtr.h and nsRefPtr.h can use.
2. Ensuring that the nsRefPtr constructor/operator= nsCOMPtr_helper overloads don't require a complete definition of nsCOMPtr_helper until they are actually used.
Doing this means that instantiations of nsRefPtr<T> won't require
nsCOMPtr_helper::operator() to be defined.  Only actual uses of the
overloads will require the definition.
Attachment #8519976 - Flags: review?(benjamin)
Attachment #8519976 - Flags: review?(benjamin) → review+
Attachment #8519978 - Flags: review?(benjamin) → review+
Attachment #8519979 - Flags: review?(benjamin) → review+
Assignee: nobody → nfroyd
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: