Define a new trait, `proc::builtins::OverloadSet`, for types that
represent a Naga IR builtin function's set of overloads. The
`OverloadSet` trait includes operations needed to validate calls,
choose automatic type conversions, and generate diagnostics.
Add a new function, `ir::MathFunction::overloads`, which returns the
given `MathFunction`'s set of overloads as an `impl OverloadSet`
value. Use this in the WGSL front end, the validator, and the
typifier.
To support `MathFunction::overloads`, provide two implementations
of `OverloadSet`:
- `List` is flexible but verbose.
- `Regular` is concise but more restrictive.
Some snapshot output is affected because `TypeResolution::Handle`
values turn into `TypeResolution::Value`, since the function database
constructs the return type directly.
To work around #7405, avoid offering abstract-typed overloads of some
functions.
This addresses #6443 for `MathFunction`, although that issue covers
other categories of operations as well.
In `naga::front::wgsl::lower`, add a new method,
`ExpressionContext::is_const`, for looking up the constness of a given
expression. Change existing code to use it.
The config can be made more precise so as to not accidentally
ignore some issues due to case (in-)sensitivity and searching for
substrings with `extend-words`.
Additionally, we can check the configuration directories as
well like `.github`.
The usage of `implace_it` went away some time ago, but not all
references were removed.