mirror of
https://github.com/gbdev/rgbds.git
synced 2026-05-11 20:31:43 +00:00
Refactor lexing of fixed-point numbers (#1915)
This incidentally fixes a bug with too-long fixed-point literals that have precision suffixes.
This commit is contained in:
@@ -8,8 +8,12 @@ println 1.q2
|
||||
|
||||
; bad
|
||||
println 12.34q0
|
||||
println 12.34q_15
|
||||
println 12.34q1_5
|
||||
println 12.34q_15 ; lexes as `12.34q` (invalid) then symbol `_15`
|
||||
println 12.34q1_5 ; lexes as `12.34q1` (valid) then symbol `_5`
|
||||
println 1_.2
|
||||
println 1._2
|
||||
println 1.__2
|
||||
println 1.2q
|
||||
println 1.999_999_999_999_999
|
||||
println 1.999_999_999_999_999q16
|
||||
println 1.999_999_999_999_999q.16
|
||||
|
||||
Reference in New Issue
Block a user