fixes #25074; Long integer literal truncated without warning (#25449)

fixes #25074

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
(cherry picked from commit ace09b3cab)
This commit is contained in:
ringabout
2026-01-23 21:52:37 +08:00
committed by narimiran
parent a4982bd74d
commit ba8ff51f2d
3 changed files with 37 additions and 2 deletions

6
tests/lexer/t25074.nim Normal file
View File

@@ -0,0 +1,6 @@
discard """
matrix: "--warningaserror:longliterals"
errormsg: "number has 64 digits but type only supports 16 digits: '0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff' [LongLiterals]"
"""
echo $sizeof 0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff