mirror of
https://github.com/encounter/dawn-cmake.git
synced 2025-08-06 04:05:40 +00:00
This CL catches up the internals (along with a few error messages) to say `initializer` instead of `constructor. Bug: tint:1600 Change-Id: I8e56572c310d77da1130380bdd32b334f27c8e46 Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/106462 Reviewed-by: Antonio Maiorano <amaiorano@google.com> Auto-Submit: Dan Sinclair <dsinclair@chromium.org> Kokoro: Kokoro <noreply+kokoro@google.com> Commit-Queue: Antonio Maiorano <amaiorano@google.com>
31 lines
863 B
Cheetah
31 lines
863 B
Cheetah
{{- /*
|
|
--------------------------------------------------------------------------------
|
|
Template file for use with tools/src/cmd/gen to generate init_conv_intrinsic.cc
|
|
|
|
To update the generated file, run:
|
|
./tools/run gen
|
|
|
|
See:
|
|
* tools/src/cmd/gen for structures used by this template
|
|
* https://golang.org/pkg/text/template/ for documentation on the template syntax
|
|
--------------------------------------------------------------------------------
|
|
*/ -}}
|
|
|
|
#include "src/tint/resolver/init_conv_intrinsic.h"
|
|
|
|
namespace tint::resolver {
|
|
|
|
const char* str(InitConvIntrinsic i) {
|
|
switch (i) {
|
|
case InitConvIntrinsic::kNone:
|
|
return "<none>";
|
|
{{- range Sem.InitializersAndConverters }}
|
|
case InitConvIntrinsic::k{{Title .Name}}:
|
|
return "{{.Name}}";
|
|
{{- end }}
|
|
}
|
|
return "<unknown>";
|
|
}
|
|
|
|
} // namespace tint::resolver
|