mirror of
https://github.com/encounter/dawn-cmake.git
synced 2025-12-15 16:16:08 +00:00
RefBase: remove implicit conversion to bool.
This helps push for comparing against nullptr more consistently. Also replaces .Get() == nullptr and .Get() != nullptr with just == nullptr and != nullptr. Bug: dawn:89 Change-Id: I884a4819f97305a73c11bad84391d1d2113ab7e2 Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/32922 Reviewed-by: Austin Eng <enga@chromium.org> Reviewed-by: Stephen White <senorblanco@chromium.org> Commit-Queue: Corentin Wallez <cwallez@chromium.org>
This commit is contained in:
committed by
Commit Bot service account
parent
a0758a1aef
commit
55f251dffe
@@ -23,7 +23,7 @@ namespace dawn_native {
|
||||
|
||||
ErrorScope::ErrorScope(wgpu::ErrorFilter errorFilter, ErrorScope* parent)
|
||||
: RefCounted(), mErrorFilter(errorFilter), mParent(parent), mIsRoot(false) {
|
||||
ASSERT(mParent.Get() != nullptr);
|
||||
ASSERT(mParent != nullptr);
|
||||
}
|
||||
|
||||
ErrorScope::~ErrorScope() {
|
||||
@@ -124,9 +124,9 @@ namespace dawn_native {
|
||||
Ref<ErrorScope> parentScope = nullptr;
|
||||
for (; !currentScope->IsRoot(); currentScope = parentScope.Get()) {
|
||||
ASSERT(!currentScope->IsRoot());
|
||||
ASSERT(currentScope.Get() != nullptr);
|
||||
ASSERT(currentScope != nullptr);
|
||||
parentScope = std::move(currentScope->mParent);
|
||||
ASSERT(parentScope.Get() != nullptr);
|
||||
ASSERT(parentScope != nullptr);
|
||||
|
||||
// On shutdown, error scopes that have yet to have a status get Unknown.
|
||||
if (currentScope->mErrorType == wgpu::ErrorType::NoError) {
|
||||
|
||||
Reference in New Issue
Block a user