From 9f9bfa3646e2132c7b5309566fbe525c8bae4d60 Mon Sep 17 00:00:00 2001 From: Kirk Scheibelhut Date: Thu, 19 Oct 2023 14:32:44 -0700 Subject: [PATCH] langref: update to document --error-limit flag This flag was added in #17532 to close #786, but the language reference was never updated to reflect the change. --- doc/langref.html.in | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/doc/langref.html.in b/doc/langref.html.in index 219a9558d672..21d400ed84bf 100644 --- a/doc/langref.html.in +++ b/doc/langref.html.in @@ -5373,8 +5373,9 @@ test "fn reflection" { gets assigned the same integer value.

- The number of unique error values across the entire compilation should determine the size of the error set type. - However right now it is hard coded to be a {#syntax#}u16{#endsyntax#}. See #786. + The error set type defaults to a {#syntax#}u16{#endsyntax#}, though if the maximum number of distinct + error values is provided via the --error-limit [num] command line parameter an integer type + with the minimum number of bits required to represent all of the error values will be used.

You can {#link|coerce|Type Coercion#} an error from a subset to a superset: