mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-24 05:11:16 +00:00
Bug 1632099 - P1. Have nsQueryObject accept const smart pointers. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D80385
This commit is contained in:
parent
34be3870be
commit
fadd7f165d
@ -61,12 +61,12 @@ inline nsQueryObject<T> do_QueryObject(T* aRawPtr) {
|
||||
}
|
||||
|
||||
template <class T>
|
||||
inline nsQueryObject<T> do_QueryObject(nsCOMPtr<T>& aRawPtr) {
|
||||
inline nsQueryObject<T> do_QueryObject(const nsCOMPtr<T>& aRawPtr) {
|
||||
return nsQueryObject<T>(aRawPtr);
|
||||
}
|
||||
|
||||
template <class T>
|
||||
inline nsQueryObject<T> do_QueryObject(RefPtr<T>& aRawPtr) {
|
||||
inline nsQueryObject<T> do_QueryObject(const RefPtr<T>& aRawPtr) {
|
||||
return nsQueryObject<T>(aRawPtr);
|
||||
}
|
||||
|
||||
@ -77,13 +77,13 @@ inline nsQueryObjectWithError<T> do_QueryObject(T* aRawPtr,
|
||||
}
|
||||
|
||||
template <class T>
|
||||
inline nsQueryObjectWithError<T> do_QueryObject(nsCOMPtr<T>& aRawPtr,
|
||||
inline nsQueryObjectWithError<T> do_QueryObject(const nsCOMPtr<T>& aRawPtr,
|
||||
nsresult* aErrorPtr) {
|
||||
return nsQueryObjectWithError<T>(aRawPtr, aErrorPtr);
|
||||
}
|
||||
|
||||
template <class T>
|
||||
inline nsQueryObjectWithError<T> do_QueryObject(RefPtr<T>& aRawPtr,
|
||||
inline nsQueryObjectWithError<T> do_QueryObject(const RefPtr<T>& aRawPtr,
|
||||
nsresult* aErrorPtr) {
|
||||
return nsQueryObjectWithError<T>(aRawPtr, aErrorPtr);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user