From 766e67ef3b2af42f800b281e0fa0f57c7e3d2e3f Mon Sep 17 00:00:00 2001 From: Roberto Ierusalimschy Date: Mon, 28 Dec 1998 11:44:54 -0200 Subject: to avoid warnings about "typecast" (Visual C++) --- lmathlib.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'lmathlib.c') diff --git a/lmathlib.c b/lmathlib.c index 181ee8d4..1d99df32 100644 --- a/lmathlib.c +++ b/lmathlib.c @@ -1,5 +1,5 @@ /* -** $Id: lmathlib.c,v 1.10 1998/06/19 16:14:09 roberto Exp roberto $ +** $Id: lmathlib.c,v 1.11 1998/09/08 19:25:35 roberto Exp roberto $ ** Lua standard mathematical library ** See Copyright Notice in lua.h */ @@ -122,7 +122,7 @@ static void math_frexp (void) { } static void math_ldexp (void) { - lua_pushnumber(ldexp(luaL_check_number(1), luaL_check_number(2))); + lua_pushnumber(ldexp(luaL_check_number(1), luaL_check_int(2))); } @@ -166,9 +166,8 @@ static void math_random (void) } -static void math_randomseed (void) -{ - srand(luaL_check_number(1)); +static void math_randomseed (void) { + srand(luaL_check_int(1)); } -- cgit v1.2.3-55-g6feb