LUA_CORE condition removed from definition of some 'tricks' (as it

controlled only a few other defines) + MS_ASMTRICK renamed to
LUA_MSASMTRICK
This commit is contained in:
Roberto Ierusalimschy 2012-10-01 11:14:45 -03:00
parent adaba04059
commit 31f7d553e4
2 changed files with 6 additions and 7 deletions

View File

@ -1,5 +1,5 @@
/*
** $Id: llimits.h,v 1.98 2012/05/11 14:10:50 roberto Exp roberto $
** $Id: llimits.h,v 1.99 2012/05/28 20:32:28 roberto Exp roberto $
** Limits, basic types, and some other `installation-dependent' definitions
** See Copyright Notice in lua.h
*/
@ -200,7 +200,7 @@ typedef lu_int32 Instruction;
** both small and large values (outside the range of integers).
*/
#if defined(MS_ASMTRICK) /* { */
#if defined(MS_ASMTRICK) || defined(LUA_MSASMTRICK) /* { */
/* trick with Microsoft assembler for X86 */
#define lua_number2int(i,n) __asm {__asm fld n __asm fistp i}

View File

@ -1,5 +1,5 @@
/*
** $Id: luaconf.h,v 1.172 2012/05/11 14:14:42 roberto Exp roberto $
** $Id: luaconf.h,v 1.173 2012/07/13 14:54:14 roberto Exp roberto $
** Configuration file for Lua
** See Copyright Notice in lua.h
*/
@ -465,13 +465,12 @@
** Some tricks with doubles
*/
#if defined(LUA_CORE) && \
defined(LUA_NUMBER_DOUBLE) && !defined(LUA_ANSI) /* { */
#if defined(LUA_NUMBER_DOUBLE) && !defined(LUA_ANSI) /* { */
/*
** The next definitions activate some tricks to speed up the
** conversion from doubles to integer types, mainly to LUA_UNSIGNED.
**
@@ MS_ASMTRICK uses Microsoft assembler to avoid clashes with a
@@ LUA_MSASMTRICK uses Microsoft assembler to avoid clashes with a
** DirectX idiosyncrasy.
**
@@ LUA_IEEE754TRICK uses a trick that should work on any machine
@ -495,7 +494,7 @@
/* Microsoft compiler on a Pentium (32 bit) ? */
#if defined(LUA_WIN) && defined(_MSC_VER) && defined(_M_IX86) /* { */
#define MS_ASMTRICK
#define LUA_MSASMTRICK
#define LUA_IEEEENDIAN 0
#define LUA_NANTRICK