Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ruanhaishen
Nodemcu Firmware
Commits
d1be80e4
Commit
d1be80e4
authored
Sep 25, 2020
by
philip
Committed by
Marcel Stör
Nov 07, 2020
Browse files
Conditionalize int2float on lua 5.3
parent
9ca1672f
Changes
1
Hide whitespace changes
Inline
Side-by-side
app/modules/node.c
View file @
d1be80e4
...
...
@@ -644,6 +644,7 @@ static int node_writercr (lua_State *L) {
return
1
;
}
#if LUA_VERSION_NUM > 501
static
int
node_int2float
(
lua_State
*
L
)
{
union
{
lua_Integer
i
;
...
...
@@ -666,6 +667,7 @@ static int node_float2int(lua_State *L) {
return
1
;
}
#endif
#endif
// Lua: n = node.LFS.reload(lfsimage)
static
int
node_lfsreload
(
lua_State
*
L
)
{
...
...
@@ -932,13 +934,16 @@ LROT_BEGIN(node, NULL, 0)
LROT_FUNCENTRY
(
restore
,
node_restore
)
LROT_FUNCENTRY
(
random
,
node_random
)
LROT_FUNCENTRY
(
stripdebug
,
node_stripdebug
)
LROT_FUNCENTRY
(
peek
,
node_peek
)
#if LUA_VERSION_NUM == 501
LROT_TABENTRY
(
egc
,
node_egc
)
#endif
#ifdef DEVELOPMENT_TOOLS
LROT_FUNCENTRY
(
osprint
,
node_osprint
)
#if LUA_VERSION_NUM > 501
LROT_FUNCENTRY
(
int2float
,
node_int2float
)
LROT_FUNCENTRY
(
float2int
,
node_float2int
)
#endif
#endif
LROT_FUNCENTRY
(
getpartitiontable
,
node_getpartitiontable
)
LROT_FUNCENTRY
(
setpartitiontable
,
node_setpartitiontable
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment