Validator: Fix GCC unused variable warning / error

Change-Id: I36e1a86328249abccfde4e6b7712d6e2a9d32c7b
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/45286
Reviewed-by: Antonio Maiorano <amaiorano@google.com>
Commit-Queue: Ben Clayton <bclayton@google.com>
This commit is contained in:
Ben Clayton 2021-03-18 20:05:34 +00:00 committed by Commit Bot service account
parent 9970ec63ca
commit c98dedf57a
1 changed files with 1 additions and 1 deletions

View File

@ -71,7 +71,7 @@ bool ValidatorImpl::Validate() {
// Validate global declarations in the order they appear in the module.
for (auto* decl : program_->AST().GlobalDeclarations()) {
if (auto* ty = decl->As<type::Type>()) {
if (decl->Is<type::Type>()) {
// Validated by Resolver (Struct types only)
return true;
} else if (auto* func = decl->As<ast::Function>()) {