Note maximum integer literal for IntLiteralTooLarge

This commit is contained in:
clubby789 2023-01-02 03:52:29 +00:00
parent e11cb36c75
commit cafdd2f7bb
2 changed files with 2 additions and 0 deletions

View File

@ -85,6 +85,7 @@ session_invalid_float_literal_suffix = invalid suffix `{$suffix}` for float lite
.help = valid suffixes are `f32` and `f64`
session_int_literal_too_large = integer literal is too large
.note = value exceeds limit of 340282366920938463463374607431768211455
session_invalid_int_literal_width = invalid width `{$width}` for integer literal
.help = valid widths are 8, 16, 32, 64 and 128

View File

@ -260,6 +260,7 @@ pub(crate) struct InvalidFloatLiteralSuffix {
#[derive(Diagnostic)]
#[diag(session_int_literal_too_large)]
#[note]
pub(crate) struct IntLiteralTooLarge {
#[primary_span]
pub span: Span,