Roberto Ierusalimschy
|
7c4cc505db
|
added "reasonable" limit for 'string.rep' (otherwise it is too easy
to crash the machine)
|
2013-06-20 12:06:51 -03:00 |
|
Roberto Ierusalimschy
|
453450d687
|
new macro 'l_floor' (allows 'floorf' even when other math operations
do not have an 'f' variant)
|
2013-06-20 12:02:49 -03:00 |
|
Roberto Ierusalimschy
|
55f566bd22
|
use lua_Integer for integer parameters to avoid truncation
|
2013-06-19 11:29:01 -03:00 |
|
Roberto Ierusalimschy
|
130c0e40e0
|
new constant 'MAX_SIZE', distinct from 'MAX_SIZET', for sizes visible
from Lua; these must fit in a lua_Integer
|
2013-06-19 11:27:00 -03:00 |
|
Roberto Ierusalimschy
|
c72fb1cf8e
|
detail (removed 'assert')
|
2013-06-14 17:46:40 -03:00 |
|
Roberto Ierusalimschy
|
138e69cc55
|
correct error message for floating-point values out of (integer) range
|
2013-06-14 15:34:49 -03:00 |
|
Roberto Ierusalimschy
|
53210d7e5b
|
correct way (I hope) to convert floats to unsigned int
|
2013-06-14 15:32:45 -03:00 |
|
Roberto Ierusalimschy
|
0394314c7a
|
avoid using a negative value to test 'lua_tounsigned'
|
2013-06-14 15:12:53 -03:00 |
|
Roberto Ierusalimschy
|
0beeb4f6fa
|
configuration of number sizes goes "mainstream"
|
2013-06-13 16:35:08 -03:00 |
|
Roberto Ierusalimschy
|
788b251157
|
'math.random' operates with integers when used for integer results
(1 or 2 parameters)
|
2013-06-13 16:32:52 -03:00 |
|
Roberto Ierusalimschy
|
318575627f
|
avoid adding '.0' to "numbers" like "nan" and "inf"
|
2013-06-07 16:02:05 -03:00 |
|
Roberto Ierusalimschy
|
a14992992a
|
new version (5.3)
|
2013-06-07 16:01:50 -03:00 |
|
Roberto Ierusalimschy
|
48adb6984c
|
'io.write' writes integers directly (and correctly)
|
2013-06-07 16:01:35 -03:00 |
|
Roberto Ierusalimschy
|
c5069528e1
|
details ('Type* id' -> 'Type *id')
|
2013-06-07 11:51:10 -03:00 |
|
Roberto Ierusalimschy
|
6fb0b11350
|
string contatenation handles conversion of integers to strings +
floats always format as floats (with decimal dot or exponent)
|
2013-06-04 16:36:42 -03:00 |
|
Roberto Ierusalimschy
|
932e7fb0e1
|
'lua_tounsigned' takes number modulo 2^numbits as a result when
number is a float
(That may change...)
|
2013-06-04 16:34:51 -03:00 |
|
Roberto Ierusalimschy
|
188192ce9a
|
'luai_hashnum' "inlined" into 'hashfloat'
|
2013-05-29 11:05:03 -03:00 |
|
Roberto Ierusalimschy
|
fc083f1138
|
removed all tricks for conversions + 'luai_hashnum' moved to ltable.c
|
2013-05-29 11:04:15 -03:00 |
|
Roberto Ierusalimschy
|
ee865b9fe7
|
new implementation for 'lua_strx2number' to correct small
problems with numbers like 0x10000...000p-100
|
2013-05-27 14:42:38 -03:00 |
|
Roberto Ierusalimschy
|
d630daca1a
|
"legal" way to convert a float to an integer in C
|
2013-05-27 09:43:37 -03:00 |
|
Roberto Ierusalimschy
|
8c883cb4e8
|
'objlen' can return integers
|
2013-05-26 11:47:51 -03:00 |
|
Roberto Ierusalimschy
|
c75cca0559
|
detail (case '%d' of 'luaO_pushvfstring' should use integers)
|
2013-05-26 11:43:35 -03:00 |
|
Roberto Ierusalimschy
|
1414b7123c
|
support for the case when 'l_mathop' does not conform to lua_Number
(problem with pointers to lua_Number solved by a typedef selected
automatically by 'l_mathop')
|
2013-05-26 10:45:24 -03:00 |
|
Roberto Ierusalimschy
|
3563b3f519
|
first version of control for number sizes (still in 'local' section)
|
2013-05-26 10:35:52 -03:00 |
|
Roberto Ierusalimschy
|
d46ed54646
|
no more IEEE tricks
|
2013-05-26 10:26:34 -03:00 |
|
Roberto Ierusalimschy
|
e2c8c756ee
|
removed 'IEEE tricks' (should not be needed in Lua with integers)
|
2013-05-23 18:27:06 -03:00 |
|
Roberto Ierusalimschy
|
5ca5086c19
|
'tonumber' now works with integers too
|
2013-05-16 15:35:57 -03:00 |
|
Roberto Ierusalimschy
|
2d6a0ae149
|
added patch to last bug
|
2013-05-16 13:03:50 -03:00 |
|
Roberto Ierusalimschy
|
b5ec26101f
|
new API function 'lua_cvtonum' to convert a value (number or string)
to a number, following the rules of the language to create integers
or floats
|
2013-05-14 13:00:11 -03:00 |
|
Roberto Ierusalimschy
|
36e8771076
|
'luaO_str2int' more generic: accepts white spaces around the numeral
and handles signal
|
2013-05-14 12:59:04 -03:00 |
|
Roberto Ierusalimschy
|
27f09415e3
|
new read format "*i" for reading integers
|
2013-05-14 12:57:43 -03:00 |
|
Roberto Ierusalimschy
|
4ad9970649
|
uses integers for time
|
2013-05-14 12:57:11 -03:00 |
|
Roberto Ierusalimschy
|
bef345a4b8
|
bug: Wrong error message in some short-cut expressions
|
2013-05-13 13:17:47 -03:00 |
|
Roberto Ierusalimschy
|
0ce3018109
|
'pushnum' pushes a "number" (float) + new C instruction 'pushint'
|
2013-05-07 16:01:16 -03:00 |
|
Roberto Ierusalimschy
|
0233ce0815
|
new function 'math.numbits' (not a final decision)
|
2013-05-06 14:22:55 -03:00 |
|
Roberto Ierusalimschy
|
1f2b82bf25
|
correct way to avoid compile-time errors in integer divisions
|
2013-05-06 14:22:16 -03:00 |
|
Roberto Ierusalimschy
|
f2043b7a58
|
correct error message for conversion errors from float to int
|
2013-05-06 14:21:59 -03:00 |
|
Roberto Ierusalimschy
|
2b1c2c61b0
|
bug: Wrong assert when reporting concatenation errors.
|
2013-05-06 14:21:28 -03:00 |
|
Roberto Ierusalimschy
|
fa6ea831b3
|
macro 'nvalue' removed (direct conversion from integer to double,
without an intermediate variable, can cause "excessive precision"
|
2013-05-06 14:17:09 -03:00 |
|
Roberto Ierusalimschy
|
b22a4280c6
|
macro 'nvalue' removed + cast to void added to avoid warnings
with 'clang'
|
2013-05-06 14:17:09 -03:00 |
|
Roberto Ierusalimschy
|
29fe3abda2
|
new function 'math.isfloat'
|
2013-05-02 14:31:54 -03:00 |
|
Roberto Ierusalimschy
|
6347004be9
|
stack overflow in vararg functions + garbage collector in recursive loops
|
2013-05-02 13:13:27 -03:00 |
|
Roberto Ierusalimschy
|
67532d5a10
|
constant folding and API arithmetic with integers
|
2013-05-02 09:37:24 -03:00 |
|
Roberto Ierusalimschy
|
6920a7f2e3
|
new macro 'intop' (to perform integer arithmetic on unsigned types)
|
2013-05-02 09:31:26 -03:00 |
|
Roberto Ierusalimschy
|
88bf2f83c0
|
new function 'tointeger' + 'luaV_arith' replaced by 'luaT_trybinTM'
|
2013-04-29 14:12:50 -03:00 |
|
Roberto Ierusalimschy
|
8fff05f6d0
|
integer division operates only on integers
|
2013-04-29 14:12:12 -03:00 |
|
Roberto Ierusalimschy
|
9b9becf384
|
added 'const' to parameters of 'luaG_concaterror'
|
2013-04-29 13:58:10 -03:00 |
|
Roberto Ierusalimschy
|
00744a2729
|
'luaO_arith' -> 'luaO_numarith'
|
2013-04-29 13:57:48 -03:00 |
|
Roberto Ierusalimschy
|
b4be507578
|
new function 'luaT_trybinTM'
|
2013-04-29 13:56:50 -03:00 |
|
Roberto Ierusalimschy
|
360587f319
|
favoring 'tonumber' over 'nvalue'
|
2013-04-26 16:51:17 -03:00 |
|