Fixed up |NS_IF_ADDREF| to support the following use efficiently in the non-logging case

This commit is contained in:
scc%netscape.com 2000-02-11 07:12:02 +00:00
parent 99f85886b8
commit b7de524c75
2 changed files with 2 additions and 2 deletions

View File

@ -857,7 +857,7 @@ NS_IMETHODIMP _class::QueryInterface(REFNSIID aIID, void** aInstancePtr) \
template <class T>
inline
nsrefcnt
ns_if_addref( T* expr )
ns_if_addref( T expr )
// Making this a |inline| |template| allows |expr| to be evaluated only once,
// yet still denies you the ability to |AddRef()| an |nsCOMPtr|.
// Note that |NS_ADDREF()| already has this property in the non-logging case.

View File

@ -857,7 +857,7 @@ NS_IMETHODIMP _class::QueryInterface(REFNSIID aIID, void** aInstancePtr) \
template <class T>
inline
nsrefcnt
ns_if_addref( T* expr )
ns_if_addref( T expr )
// Making this a |inline| |template| allows |expr| to be evaluated only once,
// yet still denies you the ability to |AddRef()| an |nsCOMPtr|.
// Note that |NS_ADDREF()| already has this property in the non-logging case.