Wiki

Ticket #132 (closed defect: fixed)

Opened 16 years ago

Last modified 16 years ago

Fractional Literals dont parse to non Decimal -number type

Reported by: hopscc Owned by: Chuck
Priority: medium Milestone:
Component: Cobra Compiler Version: 0.8.0
Keywords: Cc:

Description

Assign a large (fractional) literal ( outside Decimal range) to a number, then set -number to float* the literal is still parsed as
a Decimal ( and gives Overflow error)

	# literal < max Decimal
	a as number = 79_228_162_514_264_337_593_543_950_334.1 # parse OK
	# literal > max decimal
	# fail compile with -number:decimal
	# should compile with -number:float(32,64) - but doesnt unless
	# type the literal to float*
	b as number = 80_228_162_514_264_337_593_543_950_335.1
	#b as number = 80_228_162_514_264_337_593_543_950_335.1f

Attachments

ticket132-number-fractional-lit.patch Download (4.3 KB) - added by hopscc 16 years ago.

Change History

Changed 16 years ago by hopscc

Changed 16 years ago by hopscc

  • owner set to Chuck
  • status changed from new to assigned

Patch, test files and rel notes addition
This patch also corrects the stack dump for overflow parsing Fractional Literal
(with an error message) but only that one case.

Changed 16 years ago by Chuck

  • status changed from assigned to accepted

Changed 16 years ago by Chuck

  • status changed from accepted to closed
  • resolution set to fixed

Applied in changeset:1917. Thanks.

Note: See TracTickets for help on using tickets.