diff --git a/src/reader/wgsl/parser_impl.cc b/src/reader/wgsl/parser_impl.cc index 89cb4e956c..649589bf17 100644 --- a/src/reader/wgsl/parser_impl.cc +++ b/src/reader/wgsl/parser_impl.cc @@ -137,7 +137,6 @@ const char kBuiltinDecoration[] = "builtin"; const char kGroupDecoration[] = "group"; const char kLocationDecoration[] = "location"; const char kOffsetDecoration[] = "offset"; -const char kSetDecoration[] = "set"; const char kStageDecoration[] = "stage"; const char kStrideDecoration[] = "stride"; const char kWorkgroupSizeDecoration[] = "workgroup_size"; @@ -150,9 +149,8 @@ bool is_decoration(Token t) { return s == kAccessDecoration || s == kBindingDecoration || s == kBlockDecoration || s == kBuiltinDecoration || s == kLocationDecoration || s == kOffsetDecoration || - s == kSetDecoration || s == kGroupDecoration || - s == kStageDecoration || s == kStrideDecoration || - s == kWorkgroupSizeDecoration; + s == kGroupDecoration || s == kStageDecoration || + s == kStrideDecoration || s == kWorkgroupSizeDecoration; } /// Enter-exit counters for block token types. @@ -2937,7 +2935,7 @@ Maybe ParserImpl::decoration() { }); } - if (s == kSetDecoration || s == kGroupDecoration) { + if (s == kGroupDecoration) { const char* use = "group decoration"; return expect_paren_block(use, [&]() -> Result { auto val = expect_positive_sint(use); diff --git a/src/reader/wgsl/parser_impl_variable_decoration_test.cc b/src/reader/wgsl/parser_impl_variable_decoration_test.cc index 9cf65ab04f..128ec8aabe 100644 --- a/src/reader/wgsl/parser_impl_variable_decoration_test.cc +++ b/src/reader/wgsl/parser_impl_variable_decoration_test.cc @@ -236,22 +236,6 @@ TEST_F(ParserImplTest, VariableDecoration_Binding_MissingInvalid) { "1:9: expected signed integer literal for binding decoration"); } -// DEPRECATED -TEST_F(ParserImplTest, VariableDecoration_set) { - auto p = parser("set(4)"); - auto deco = p->decoration(); - EXPECT_TRUE(deco.matched); - EXPECT_FALSE(deco.errored); - ASSERT_NE(deco.value, nullptr); - auto* var_deco = deco.value->As(); - ASSERT_FALSE(p->has_error()); - ASSERT_NE(var_deco, nullptr); - ASSERT_TRUE(var_deco->Is()); - - auto* group = var_deco->As(); - EXPECT_EQ(group->value(), 4u); -} - TEST_F(ParserImplTest, VariableDecoration_group) { auto p = parser("group(4)"); auto deco = p->decoration();