Remove Function::name().

This CL removes the function name accessor and changes all usages to use
the symbol.

Change-Id: I19b92bf1bc557ba14e68ef8cb381487a4ad1f7ee
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/36821
Reviewed-by: Ben Clayton <bclayton@google.com>
This commit is contained in:
dan sinclair
2021-01-11 16:24:32 +00:00
committed by dan sinclair
parent eb737c25db
commit 4ac6568821
11 changed files with 38 additions and 52 deletions

View File

@@ -160,14 +160,14 @@ bool ValidatorImpl::ValidateEntryPoint(const ast::FunctionList& funcs) {
if (!func->params().empty()) {
add_error(func->source(), "v-0023",
"Entry point function must accept no parameters: '" +
func->name() + "'");
module_.SymbolToName(func->symbol()) + "'");
return false;
}
if (!func->return_type()->Is<ast::type::Void>()) {
add_error(
func->source(), "v-0024",
"Entry point function must return void: '" + func->name() + "'");
add_error(func->source(), "v-0024",
"Entry point function must return void: '" +
module_.SymbolToName(func->symbol()) + "'");
return false;
}
auto stage_deco_count = 0;