mirror of
https://github.com/rust-lang/rust.git
synced 2025-10-03 18:57:19 +00:00

Currently, the only API for creating errors from a diagnostic derive will emit it immediately. This makes it difficult to add subdiagnostics to diagnostics from the derive, so add `create_{err,warning}` functions that return the diagnostic without emitting it. Signed-off-by: David Wood <david.wood@huawei.com>