4d1a935835
Previously, when attempting to cast a huge value to an int, SkSL would report an error, then return the IR for `ScalarCast(Int, FloatLiteral(huge-value))` . Now, to minimize the blast radius of the error, we report the error but return `IntLiteral(0)`. We've already reported an error, so there's no need to preserve the value, and zero is less likely to produce follow-up errors. (A similar approach is used here and worked well: https://osscs.corp.google.com/skia/skia/+/main:src/sksl/ir/SkSLConstructorCompoundCast.cpp;l=57-59) Change-Id: Ie8e8d48380cb963466d1f47d123d64e3301cf87c Reviewed-on: https://skia-review.googlesource.com/c/skia/+/499563 Auto-Submit: John Stiles <johnstiles@google.com> Reviewed-by: Ethan Nicholas <ethannicholas@google.com> Commit-Queue: John Stiles <johnstiles@google.com> |
||
---|---|---|
.. | ||
blend | ||
errors | ||
folding | ||
glsl | ||
inliner | ||
intrinsics | ||
metal | ||
runtime | ||
runtime_errors | ||
shared | ||
spirv | ||
workarounds | ||
README.txt |
This directory contains skslc-compiled output from matching source files in the /resources/sksl/ directory.