From 5a009f2c4ce958779ec62ef1af096433dd481462 Mon Sep 17 00:00:00 2001 From: Marc Autret Date: Mon, 13 Aug 2001 21:10:10 +0000 Subject: [PATCH] * src/bison.simple (_yy_memcpy): CPP reformat. --- ChangeLog | 4 ++++ src/bison.simple | 23 +++++------------------ 2 files changed, 9 insertions(+), 18 deletions(-) diff --git a/ChangeLog b/ChangeLog index 575f09d0..4b0d7324 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2001-08-13 Marc Autret + + * src/bison.simple (_yy_memcpy): CPP reformat. + 2001-08-13 Pascal Bart * tests/atconfig.in (CPPFLAGS): Fix. diff --git a/src/bison.simple b/src/bison.simple index a073070c..77b54685 100644 --- a/src/bison.simple +++ b/src/bison.simple @@ -185,40 +185,27 @@ int yydebug; #if __GNUC__ > 1 /* GNU C and GNU C++ define this. */ # define __yy_memcpy(To, From, Count) __builtin_memcpy (To, From, Count) #else /* not GNU C or C++ */ -# ifndef __cplusplus /* This is the most reliable way to avoid incompatibilities in available built-in functions on various systems. */ static void +# ifndef __cplusplus __yy_memcpy (to, from, count) char *to; - char *from; + const char *from; unsigned int count; -{ - register char *f = from; - register char *t = to; - register int i = count; - - while (i-- > 0) - *t++ = *f++; -} - # else /* __cplusplus */ - -/* This is the most reliable way to avoid incompatibilities - in available built-in functions on various systems. */ -static void -__yy_memcpy (char *to, char *from, unsigned int count) +__yy_memcpy (char *to, const char *from, unsigned int count) +# endif { + register const char *f = from; register char *t = to; - register char *f = from; register int i = count; while (i-- > 0) *t++ = *f++; } -# endif #endif #line -- 2.45.2