summaryrefslogtreecommitdiff
path: root/lvm.c
diff options
context:
space:
mode:
Diffstat (limited to 'lvm.c')
-rw-r--r--lvm.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/lvm.c b/lvm.c
index 5e7764bd..8944da01 100644
--- a/lvm.c
+++ b/lvm.c
@@ -1,5 +1,5 @@
1/* 1/*
2** $Id: lvm.c,v 2.229 2014/11/19 15:05:15 roberto Exp roberto $ 2** $Id: lvm.c,v 2.230 2014/11/21 12:15:00 roberto Exp roberto $
3** Lua virtual machine 3** Lua virtual machine
4** See Copyright Notice in lua.h 4** See Copyright Notice in lua.h
5*/ 5*/
@@ -74,8 +74,7 @@ int luaV_tonumber_ (const TValue *obj, lua_Number *n) {
74 } 74 }
75 else if (cvt2num(obj) && /* string convertible to number? */ 75 else if (cvt2num(obj) && /* string convertible to number? */
76 luaO_str2num(svalue(obj), &v) == tsvalue(obj)->len + 1) { 76 luaO_str2num(svalue(obj), &v) == tsvalue(obj)->len + 1) {
77 /* convert result of 'luaO_str2num' to a float */ 77 *n = nvalue(&v); /* convert result of 'luaO_str2num' to a float */
78 *n = (ttisinteger(&v)) ? cast_num(ivalue(&v)) : fltvalue(&v);
79 return 1; 78 return 1;
80 } 79 }
81 else 80 else