Roku Developer Program

Developers and content creators—a complete solution for growing an audience directly.
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Level 9

BRS Type promotion bug?

From the lang.reference, 3.5 Type Conversion (Promotion):
... If the result of an integer *, -, or + operation is outside the integer range, the operation will be done in double precision and the result will be double precision.

Does not seem to be the case though:
BSD> ? 65536*65536, 65536*32768
0 -2147483648
BSD> ? 2^30, 2^31, 2^32
1073741824 -2147483648 0

So either documentation or the implementation must be wrong. Which one?
0 Kudos
1 Reply
Roku Employee
Roku Employee

Re: BRS Type promotion bug?

Bug filed.

- Joel
0 Kudos