From: Richard M. Stallman Date: Sat, 11 May 1996 19:19:55 +0000 (+0000) Subject: (__yy_memcpy): Really reorder the args, as was supposedly done on Feb 14 1995. X-Git-Tag: GNU_ORIG~33 X-Git-Url: https://git.saurik.com/bison.git/commitdiff_plain/c245d0d38d2285834016a3815a9a0e8e02eca212?hp=ba2e357c0d9b3abe67868d3660f5f049716394ba (__yy_memcpy): Really reorder the args, as was supposedly done on Feb 14 1995. (yyparse): Calls changed accordingly. --- diff --git a/bison.simple b/bison.simple index 5a9cac45..aea6b78c 100644 --- a/bison.simple +++ b/bison.simple @@ -154,16 +154,16 @@ int yyparse (void); #endif #if __GNUC__ > 1 /* GNU C and GNU C++ define this. */ -#define __yy_memcpy(FROM,TO,COUNT) __builtin_memcpy(TO,FROM,COUNT) +#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 -__yy_memcpy (from, to, count) - char *from; +__yy_memcpy (to, from, count) char *to; + char *from; int count; { register char *f = from; @@ -179,7 +179,7 @@ __yy_memcpy (from, to, count) /* This is the most reliable way to avoid incompatibilities in available built-in functions on various systems. */ static void -__yy_memcpy (char *from, char *to, int count) +__yy_memcpy (char *to, char *from, int count) { register char *f = from; register char *t = to; @@ -331,12 +331,12 @@ yynewstate: if (yystacksize > YYMAXDEPTH) yystacksize = YYMAXDEPTH; yyss = (short *) alloca (yystacksize * sizeof (*yyssp)); - __yy_memcpy ((char *)yyss1, (char *)yyss, size * sizeof (*yyssp)); + __yy_memcpy ((char *)yyss, (char *)yyss1, size * sizeof (*yyssp)); yyvs = (YYSTYPE *) alloca (yystacksize * sizeof (*yyvsp)); - __yy_memcpy ((char *)yyvs1, (char *)yyvs, size * sizeof (*yyvsp)); + __yy_memcpy ((char *)yyvs, (char *)yyvs1, size * sizeof (*yyvsp)); #ifdef YYLSP_NEEDED yyls = (YYLTYPE *) alloca (yystacksize * sizeof (*yylsp)); - __yy_memcpy ((char *)yyls1, (char *)yyls, size * sizeof (*yylsp)); + __yy_memcpy ((char *)yyls, (char *)yyls1, size * sizeof (*yylsp)); #endif #endif /* no yyoverflow */ diff --git a/src/bison.s1 b/src/bison.s1 index 5a9cac45..aea6b78c 100644 --- a/src/bison.s1 +++ b/src/bison.s1 @@ -154,16 +154,16 @@ int yyparse (void); #endif #if __GNUC__ > 1 /* GNU C and GNU C++ define this. */ -#define __yy_memcpy(FROM,TO,COUNT) __builtin_memcpy(TO,FROM,COUNT) +#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 -__yy_memcpy (from, to, count) - char *from; +__yy_memcpy (to, from, count) char *to; + char *from; int count; { register char *f = from; @@ -179,7 +179,7 @@ __yy_memcpy (from, to, count) /* This is the most reliable way to avoid incompatibilities in available built-in functions on various systems. */ static void -__yy_memcpy (char *from, char *to, int count) +__yy_memcpy (char *to, char *from, int count) { register char *f = from; register char *t = to; @@ -331,12 +331,12 @@ yynewstate: if (yystacksize > YYMAXDEPTH) yystacksize = YYMAXDEPTH; yyss = (short *) alloca (yystacksize * sizeof (*yyssp)); - __yy_memcpy ((char *)yyss1, (char *)yyss, size * sizeof (*yyssp)); + __yy_memcpy ((char *)yyss, (char *)yyss1, size * sizeof (*yyssp)); yyvs = (YYSTYPE *) alloca (yystacksize * sizeof (*yyvsp)); - __yy_memcpy ((char *)yyvs1, (char *)yyvs, size * sizeof (*yyvsp)); + __yy_memcpy ((char *)yyvs, (char *)yyvs1, size * sizeof (*yyvsp)); #ifdef YYLSP_NEEDED yyls = (YYLTYPE *) alloca (yystacksize * sizeof (*yylsp)); - __yy_memcpy ((char *)yyls1, (char *)yyls, size * sizeof (*yylsp)); + __yy_memcpy ((char *)yyls, (char *)yyls1, size * sizeof (*yylsp)); #endif #endif /* no yyoverflow */ diff --git a/src/bison.simple b/src/bison.simple index 5a9cac45..aea6b78c 100644 --- a/src/bison.simple +++ b/src/bison.simple @@ -154,16 +154,16 @@ int yyparse (void); #endif #if __GNUC__ > 1 /* GNU C and GNU C++ define this. */ -#define __yy_memcpy(FROM,TO,COUNT) __builtin_memcpy(TO,FROM,COUNT) +#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 -__yy_memcpy (from, to, count) - char *from; +__yy_memcpy (to, from, count) char *to; + char *from; int count; { register char *f = from; @@ -179,7 +179,7 @@ __yy_memcpy (from, to, count) /* This is the most reliable way to avoid incompatibilities in available built-in functions on various systems. */ static void -__yy_memcpy (char *from, char *to, int count) +__yy_memcpy (char *to, char *from, int count) { register char *f = from; register char *t = to; @@ -331,12 +331,12 @@ yynewstate: if (yystacksize > YYMAXDEPTH) yystacksize = YYMAXDEPTH; yyss = (short *) alloca (yystacksize * sizeof (*yyssp)); - __yy_memcpy ((char *)yyss1, (char *)yyss, size * sizeof (*yyssp)); + __yy_memcpy ((char *)yyss, (char *)yyss1, size * sizeof (*yyssp)); yyvs = (YYSTYPE *) alloca (yystacksize * sizeof (*yyvsp)); - __yy_memcpy ((char *)yyvs1, (char *)yyvs, size * sizeof (*yyvsp)); + __yy_memcpy ((char *)yyvs, (char *)yyvs1, size * sizeof (*yyvsp)); #ifdef YYLSP_NEEDED yyls = (YYLTYPE *) alloca (yystacksize * sizeof (*yylsp)); - __yy_memcpy ((char *)yyls1, (char *)yyls, size * sizeof (*yylsp)); + __yy_memcpy ((char *)yyls, (char *)yyls1, size * sizeof (*yylsp)); #endif #endif /* no yyoverflow */