Remove WGSL source from validation messages
The shader source can be very large and this is causing excessively large error messages that get truncated in some applications that use Dawn native. We don't need to see the whole shader in the error message. Change-Id: I15ad7fa7814d19875a7c28b39e5fa9a24f265b98 Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/90161 Reviewed-by: Austin Eng <enga@chromium.org> Kokoro: Kokoro <noreply+kokoro@google.com>
This commit is contained in:
parent
49385c99cc
commit
c368339da1
|
@ -380,8 +380,8 @@ ResultOrError<tint::Program> ParseWGSL(const tint::Source::File* file,
|
|||
outMessages->AddMessages(program.Diagnostics());
|
||||
}
|
||||
if (!program.IsValid()) {
|
||||
return DAWN_FORMAT_VALIDATION_ERROR("Tint WGSL reader failure:\nParser: %s\nShader:\n%s\n",
|
||||
program.Diagnostics().str(), file->content.data);
|
||||
return DAWN_FORMAT_VALIDATION_ERROR("Tint WGSL reader failure: %s\n",
|
||||
program.Diagnostics().str());
|
||||
}
|
||||
|
||||
return std::move(program);
|
||||
|
|
Loading…
Reference in New Issue