Fix test: "unknown case statement" from spirv reader
Bug found when passing program through spirv writer and then reader. Bug: tint:792 Change-Id: I904b959ba1d540b4377f8b9027286182ee0c34e9 Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/50561 Commit-Queue: Antonio Maiorano <amaiorano@google.com> Reviewed-by: Ben Clayton <bclayton@google.com>
This commit is contained in:
parent
1959cdec99
commit
f25ad24d1b
|
@ -83,7 +83,9 @@ TEST_F(ResolverTest, Stmt_Case) {
|
|||
ast::CaseSelectorList lit;
|
||||
lit.push_back(create<ast::SintLiteral>(3));
|
||||
auto* cse = create<ast::CaseStatement>(lit, block);
|
||||
WrapInFunction(v, cse);
|
||||
auto* cond_var = Var("c", ty.i32(), ast::StorageClass::kFunction);
|
||||
auto* sw = Switch(cond_var, cse, DefaultCase());
|
||||
WrapInFunction(v, cond_var, sw);
|
||||
|
||||
EXPECT_TRUE(r()->Resolve()) << r()->error();
|
||||
|
||||
|
|
Loading…
Reference in New Issue