Remove support for the old _idx builtins.
This CL removes the old _idx variants of builtins in favour of the _index versions. Change-Id: I1678b5fae63c9d4f7f63feabf7410a58505d397a Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/38825 Auto-Submit: dan sinclair <dsinclair@chromium.org> Reviewed-by: Ben Clayton <bclayton@google.com> Commit-Queue: dan sinclair <dsinclair@chromium.org>
This commit is contained in:
parent
67beed1b94
commit
c2972cfa60
|
@ -103,10 +103,10 @@ ast::Builtin ident_to_builtin(const std::string& str) {
|
|||
if (str == "position") {
|
||||
return ast::Builtin::kPosition;
|
||||
}
|
||||
if (str == "vertex_idx" || str == "vertex_index") {
|
||||
if (str == "vertex_index") {
|
||||
return ast::Builtin::kVertexIndex;
|
||||
}
|
||||
if (str == "instance_idx" || str == "instance_index") {
|
||||
if (str == "instance_index") {
|
||||
return ast::Builtin::kInstanceIndex;
|
||||
}
|
||||
if (str == "front_facing") {
|
||||
|
@ -121,7 +121,7 @@ ast::Builtin ident_to_builtin(const std::string& str) {
|
|||
if (str == "local_invocation_id") {
|
||||
return ast::Builtin::kLocalInvocationId;
|
||||
}
|
||||
if (str == "local_invocation_idx" || str == "local_invocation_index") {
|
||||
if (str == "local_invocation_index") {
|
||||
return ast::Builtin::kLocalInvocationIndex;
|
||||
}
|
||||
if (str == "global_invocation_id") {
|
||||
|
|
|
@ -113,17 +113,13 @@ INSTANTIATE_TEST_SUITE_P(
|
|||
ParserImplTest,
|
||||
BuiltinTest,
|
||||
testing::Values(BuiltinData{"position", ast::Builtin::kPosition},
|
||||
BuiltinData{"vertex_idx", ast::Builtin::kVertexIndex},
|
||||
BuiltinData{"vertex_index", ast::Builtin::kVertexIndex},
|
||||
BuiltinData{"instance_idx", ast::Builtin::kInstanceIndex},
|
||||
BuiltinData{"instance_index", ast::Builtin::kInstanceIndex},
|
||||
BuiltinData{"front_facing", ast::Builtin::kFrontFacing},
|
||||
BuiltinData{"frag_coord", ast::Builtin::kFragCoord},
|
||||
BuiltinData{"frag_depth", ast::Builtin::kFragDepth},
|
||||
BuiltinData{"local_invocation_id",
|
||||
ast::Builtin::kLocalInvocationId},
|
||||
BuiltinData{"local_invocation_idx",
|
||||
ast::Builtin::kLocalInvocationIndex},
|
||||
BuiltinData{"local_invocation_index",
|
||||
ast::Builtin::kLocalInvocationIndex},
|
||||
BuiltinData{"global_invocation_id",
|
||||
|
|
Loading…
Reference in New Issue