Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/external/mit/lua/dist/src lua: formatting in lvm.c



details:   https://anonhg.NetBSD.org/src/rev/95f7ff81484c
branches:  trunk
changeset: 374434:95f7ff81484c
user:      nikita <nikita%NetBSD.org@localhost>
date:      Sat Apr 22 19:41:15 2023 +0000

description:
lua: formatting in lvm.c

diffstat:

 external/mit/lua/dist/src/lvm.c |  20 +++++++-------------
 1 files changed, 7 insertions(+), 13 deletions(-)

diffs (63 lines):

diff -r 813e646edba5 -r 95f7ff81484c external/mit/lua/dist/src/lvm.c
--- a/external/mit/lua/dist/src/lvm.c   Sat Apr 22 18:55:59 2023 +0000
+++ b/external/mit/lua/dist/src/lvm.c   Sat Apr 22 19:41:15 2023 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: lvm.c,v 1.18 2023/04/21 17:31:33 nikita Exp $  */
+/*     $NetBSD: lvm.c,v 1.19 2023/04/22 19:41:15 nikita Exp $  */
 
 /*
 ** Id: lvm.c 
@@ -500,8 +500,8 @@ l_sinline int LEfloatint (lua_Number f, 
 /*
 ** Return 'l < r', for numbers.
 */
+l_sinline int LTnum (const TValue *l, const TValue *r) {
 #ifndef _KERNEL
-l_sinline int LTnum (const TValue *l, const TValue *r) {
   lua_assert(ttisnumber(l) && ttisnumber(r));
   if (ttisinteger(l)) {
     lua_Integer li = ivalue(l);
@@ -517,22 +517,19 @@ l_sinline int LTnum (const TValue *l, co
     else  /* 'l' is float and 'r' is int */
       return LTfloatint(lf, ivalue(r));
   }
-}
-#endif /* _KERNEL */
-#ifdef _KERNEL
-l_sinline int LTnum (const TValue *l, const TValue *r) {
+#else
   lua_assert(ttisnumber(l));
   lua_assert(ttisnumber(r));
   return ivalue(l) < ivalue(r);  /* both are integers */
+#endif /* _KERNEL */
 }
-#endif /* _KERNEL */
 
 
 /*
 ** Return 'l <= r', for numbers.
 */
+l_sinline int LEnum (const TValue *l, const TValue *r) {
 #ifndef _KERNEL
-l_sinline int LEnum (const TValue *l, const TValue *r) {
   lua_assert(ttisnumber(l) && ttisnumber(r));
   if (ttisinteger(l)) {
     lua_Integer li = ivalue(l);
@@ -548,15 +545,12 @@ l_sinline int LEnum (const TValue *l, co
     else  /* 'l' is float and 'r' is int */
       return LEfloatint(lf, ivalue(r));
   }
-}
-#endif /* _KERNEL */
-#ifdef _KERNEL
-l_sinline int LEnum (const TValue *l, const TValue *r) {
+#else
   lua_assert(ttisinteger(l));
   lua_assert(ttisinteger(r));
   return ivalue(l) <= ivalue(r);  /* both are integers */
+#endif /* _KERNEL */
 }
-#endif /* _KERNEL */
 
 
 /*



Home | Main Index | Thread Index | Old Index