Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 14 Aug 2018 18:45:21 +0000 (UTC)
From:      Warner Losh <imp@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r337808 - head/contrib/lua/src
Message-ID:  <201808141845.w7EIjLRk058905@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: imp
Date: Tue Aug 14 18:45:20 2018
New Revision: 337808
URL: https://svnweb.freebsd.org/changeset/base/337808

Log:
  When the LUA floating point model is INT64, we don't need to do the
  overflow dance. This avoids compile errors on latter-day gcc compilers
  as well as simplifies the generated code.
  
  Reviewed by: kevans@

Modified:
  head/contrib/lua/src/lvm.c

Modified: head/contrib/lua/src/lvm.c
==============================================================================
--- head/contrib/lua/src/lvm.c	Tue Aug 14 18:45:16 2018	(r337807)
+++ head/contrib/lua/src/lvm.c	Tue Aug 14 18:45:20 2018	(r337808)
@@ -41,7 +41,7 @@
 ** float without rounding. Used in comparisons. Left undefined if
 ** all integers fit in a float precisely.
 */
-#if !defined(l_intfitsf)
+#if !defined(l_intfitsf) && LUA_FLOAT_TYPE != LUA_FLOAT_INT64
 
 /* number of bits in the mantissa of a float */
 #define NBM		(l_mathlim(MANT_DIG))



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201808141845.w7EIjLRk058905>