зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1316978 - Suppress nullptr-to-bool cast warning - r=froydnj
MozReview-Commit-ID: BweUO5stduw --HG-- extra : rebase_source : 9f61f969007dc5680cbc0f8edc4f15d5f119cd4f
This commit is contained in:
Родитель
92fb3b4b8f
Коммит
33ea8d877d
|
@ -130,9 +130,11 @@ do { \
|
|||
|
||||
/* nsCOMPtr.h allows these macros to be defined by clients
|
||||
* These logging functions require dynamic_cast<void*>, so they don't
|
||||
* do anything useful if we don't have dynamic_cast<void*>. */
|
||||
* do anything useful if we don't have dynamic_cast<void*>.
|
||||
* Note: The explicit comparison to nullptr is needed to avoid warnings
|
||||
* when _p is a nullptr itself. */
|
||||
#define NSCAP_LOG_ASSIGNMENT(_c, _p) \
|
||||
if (_p) \
|
||||
if (_p != nullptr) \
|
||||
NS_LogCOMPtrAddRef((_c),static_cast<nsISupports*>(_p))
|
||||
|
||||
#define NSCAP_LOG_RELEASE(_c, _p) \
|
||||
|
|
Загрузка…
Ссылка в новой задаче