A few more improvements in 'luaO_pushvfstring'
- 'L' added to the 'BuffFS' structure - '%c' does not handle control characters (it is not its business. This now is done by the lexer, who is the one in charge of that kind of errors.) - avoid the direct use of 'l_sprintf' in the Lua kernel
This commit is contained in:
13
luaconf.h
13
luaconf.h
@@ -376,7 +376,7 @@
|
||||
@@ lua_number2str converts a float to a string.
|
||||
@@ l_mathop allows the addition of an 'l' or 'f' to all math operations.
|
||||
@@ l_floor takes the floor of a float.
|
||||
@@ lua_str2number converts a decimal numeric string to a number.
|
||||
@@ lua_str2number converts a decimal numeral to a number.
|
||||
*/
|
||||
|
||||
|
||||
@@ -568,7 +568,7 @@
|
||||
|
||||
|
||||
/*
|
||||
@@ lua_strx2number converts a hexadecimal numeric string to a number.
|
||||
@@ lua_strx2number converts a hexadecimal numeral to a number.
|
||||
** In C99, 'strtod' does that conversion. Otherwise, you can
|
||||
** leave 'lua_strx2number' undefined and Lua will provide its own
|
||||
** implementation.
|
||||
@@ -579,7 +579,14 @@
|
||||
|
||||
|
||||
/*
|
||||
@@ lua_number2strx converts a float to a hexadecimal numeric string.
|
||||
@@ lua_pointer2str converts a pointer to a readable string in a
|
||||
** non-specified way.
|
||||
*/
|
||||
#define lua_pointer2str(buff,sz,p) l_sprintf(buff,sz,"%p",p)
|
||||
|
||||
|
||||
/*
|
||||
@@ lua_number2strx converts a float to a hexadecimal numeral.
|
||||
** In C99, 'sprintf' (with format specifiers '%a'/'%A') does that.
|
||||
** Otherwise, you can leave 'lua_number2strx' undefined and Lua will
|
||||
** provide its own implementation.
|
||||
|
||||
Reference in New Issue
Block a user