Source-Changes-HG archive

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

[src/trunk]: src/external/bsd/byacc resolve conflicts



details:   https://anonhg.NetBSD.org/src/rev/aed06363581b
branches:  trunk
changeset: 785920:aed06363581b
user:      christos <christos%NetBSD.org@localhost>
date:      Sat Apr 06 14:52:24 2013 +0000

description:
resolve conflicts

diffstat:

 external/bsd/byacc/dist/closure.c        |    6 +-
 external/bsd/byacc/dist/config_h.in      |   55 ++-
 external/bsd/byacc/dist/defs.h           |   24 +-
 external/bsd/byacc/dist/error.c          |    6 +-
 external/bsd/byacc/dist/lr0.c            |    8 +-
 external/bsd/byacc/dist/main.c           |   30 +-
 external/bsd/byacc/dist/mkpar.c          |    9 +-
 external/bsd/byacc/dist/output.c         |   50 +-
 external/bsd/byacc/dist/reader.c         |   75 +-
 external/bsd/byacc/dist/skeleton.c       |    9 +-
 external/bsd/byacc/dist/symtab.c         |   13 +-
 external/bsd/byacc/dist/test/README      |    2 +-
 external/bsd/byacc/dist/test/error.tab.c |   23 +-
 external/bsd/byacc/dist/test/ftp.tab.c   |  640 ++++++++++++++++--------------
 external/bsd/byacc/dist/test/ftp.tab.h   |   49 +-
 external/bsd/byacc/dist/test/ftp.y       |  243 ++++++-----
 external/bsd/byacc/dist/verbose.c        |    9 +-
 external/bsd/byacc/dist/warshall.c       |    7 +-
 external/bsd/byacc/dist/yacc.1           |   95 ++++-
 external/bsd/byacc/include/config.h      |   57 ++-
 20 files changed, 856 insertions(+), 554 deletions(-)

diffs (truncated from 3072 to 300 lines):

diff -r 1a46c728a6a0 -r aed06363581b external/bsd/byacc/dist/closure.c
--- a/external/bsd/byacc/dist/closure.c Sat Apr 06 14:45:24 2013 +0000
+++ b/external/bsd/byacc/dist/closure.c Sat Apr 06 14:52:24 2013 +0000
@@ -1,11 +1,11 @@
-/*     $NetBSD: closure.c,v 1.6 2011/09/10 21:29:04 christos Exp $     */
+/*     $NetBSD: closure.c,v 1.7 2013/04/06 14:52:24 christos Exp $     */
 
-/* Id: closure.c,v 1.9 2010/06/09 08:21:47 tom Exp */
+/* Id: closure.c,v 1.9 2010/06/09 08:21:47 tom Exp  */
 
 #include "defs.h"
 
 #include <sys/cdefs.h>
-__RCSID("$NetBSD: closure.c,v 1.6 2011/09/10 21:29:04 christos Exp $");
+__RCSID("$NetBSD: closure.c,v 1.7 2013/04/06 14:52:24 christos Exp $");
 
 Value_t *itemset;
 Value_t *itemsetend;
diff -r 1a46c728a6a0 -r aed06363581b external/bsd/byacc/dist/config_h.in
--- a/external/bsd/byacc/dist/config_h.in       Sat Apr 06 14:45:24 2013 +0000
+++ b/external/bsd/byacc/dist/config_h.in       Sat Apr 06 14:52:24 2013 +0000
@@ -1,3 +1,52 @@
-/* @configure_input@ */
-/* Id: config_h.in,v 1.1 1995/01/01 19:34:59 tom Exp */
-@DEFS@
+/* config_h.in.  Generated automatically from configure.in by autoheader.  */
+
+/* Define to noreturn-attribute for gcc */
+#undef GCC_NORETURN
+
+/* Define to 1 if the compiler supports gcc-like printf attribute. */
+#undef GCC_PRINTF
+
+/* Define to printf-attribute for gcc */
+#undef GCC_PRINTFLIKE
+
+/* Define to 1 if the compiler supports gcc-like scanf attribute. */
+#undef GCC_SCANF
+
+/* Define to sscanf-attribute for gcc */
+#undef GCC_SCANFLIKE
+
+/* Define to unused-attribute for gcc */
+#undef GCC_UNUSED
+
+/* Define if you have the <fcntl.h> header file. */
+#undef HAVE_FCNTL_H
+
+/* Define if you have the `dbmalloc' library (-ldbmalloc). */
+#undef HAVE_LIBDBMALLOC
+
+/* Define if you have the `dmalloc' library (-ldmalloc). */
+#undef HAVE_LIBDMALLOC
+
+/* Define to 1 if mkstemp() is available and working. */
+#undef HAVE_MKSTEMP
+
+/* Define to 1 if filesystem supports mixed-case filenames. */
+#undef MIXEDCASE_FILENAMES
+
+/* Define to 1 if you want to perform memory-leak testing. */
+#undef NO_LEAKS
+
+/* Define to the system name. */
+#undef SYSTEM_NAME
+
+/* "Define to 1 if you want to use dbmalloc for testing." */
+#undef USE_DBMALLOC
+
+/* "Define to 1 if you want to use dmalloc for testing." */
+#undef USE_DMALLOC
+
+/* "Define to 1 if you want to use valgrind for testing." */
+#undef USE_VALGRIND
+
+/* Define to 1 if you want to perform memory-leak testing. */
+#undef YY_NO_LEAKS
diff -r 1a46c728a6a0 -r aed06363581b external/bsd/byacc/dist/defs.h
--- a/external/bsd/byacc/dist/defs.h    Sat Apr 06 14:45:24 2013 +0000
+++ b/external/bsd/byacc/dist/defs.h    Sat Apr 06 14:52:24 2013 +0000
@@ -1,9 +1,9 @@
-/*     $NetBSD: defs.h,v 1.5 2011/09/10 21:29:04 christos Exp $        */
+/*     $NetBSD: defs.h,v 1.6 2013/04/06 14:52:24 christos Exp $        */
 
 #if HAVE_NBTOOL_CONFIG_H
 #include "nbtool_config.h"
 #endif
-/* Id: defs.h,v 1.35 2011/09/07 08:55:03 tom Exp */
+/* Id: defs.h,v 1.37 2012/05/26 15:23:00 tom Exp  */
 
 #ifdef HAVE_CONFIG_H
 #include <config.h>
@@ -16,6 +16,10 @@
 #include <ctype.h>
 #include <stdio.h>
 
+#if defined(__cplusplus)       /* __cplusplus, etc. */
+#define class myClass
+#endif
+
 #define YYMAJOR 1
 #define YYMINOR 9
 
@@ -137,9 +141,11 @@
 #define CALLOC(k,n)    (calloc((size_t)(k),(size_t)(n)))
 #define        FREE(x)         (free((char*)(x)))
 #define MALLOC(n)      (malloc((size_t)(n)))
+#define TMALLOC(t,n)   ((t*) malloc((size_t)(n) * sizeof(t)))
 #define        NEW(t)          ((t*)allocate(sizeof(t)))
 #define        NEW2(n,t)       ((t*)allocate(((size_t)(n)*sizeof(t))))
 #define REALLOC(p,n)   (realloc((char*)(p),(size_t)(n)))
+#define TREALLOC(t,p,n)        ((t*)realloc((char*)(p), (size_t)(n) * sizeof(t)))
 
 #define DO_FREE(x)     if (x) { FREE(x); x = 0; }
 
@@ -235,6 +241,7 @@
 extern char iflag;
 extern char lflag;
 extern char rflag;
+extern char sflag;
 extern char tflag;
 extern char vflag;
 extern const char *symbol_prefix;
@@ -306,7 +313,6 @@
 extern bucket *first_symbol;
 extern bucket *last_symbol;
 
-extern int pure_parser;
 extern int nstates;
 extern core *first_state;
 extern shifts *first_shift;
@@ -347,12 +353,22 @@
 extern bucket *make_bucket(const char *);
 
 #ifndef GCC_NORETURN
+#if defined(__dead2)
+#define GCC_NORETURN           __dead2
+#elif defined(__dead)
+#define GCC_NORETURN           __dead
+#else
 #define GCC_NORETURN           /* nothing */
 #endif
+#endif
 
 #ifndef GCC_UNUSED
+#if defined(__unused)
+#define GCC_UNUSED             __unused
+#else
 #define GCC_UNUSED             /* nothing */
 #endif
+#endif
 
 /* closure.c */
 extern void closure(Value_t * nucleus, int n);
@@ -426,7 +442,7 @@
 extern void reader(void);
 
 /* skeleton.c */
-extern void write_section(FILE *fp, const char *const section[]);
+extern void write_section(FILE * fp, const char *const section[]);
 
 /* verbose.c */
 extern void verbose(void);
diff -r 1a46c728a6a0 -r aed06363581b external/bsd/byacc/dist/error.c
--- a/external/bsd/byacc/dist/error.c   Sat Apr 06 14:45:24 2013 +0000
+++ b/external/bsd/byacc/dist/error.c   Sat Apr 06 14:52:24 2013 +0000
@@ -1,10 +1,10 @@
-/*     $NetBSD: error.c,v 1.7 2011/09/10 21:29:04 christos Exp $       */
-/* Id: error.c,v 1.9 2011/09/05 23:27:43 tom Exp */
+/*     $NetBSD: error.c,v 1.8 2013/04/06 14:52:24 christos Exp $       */
 
 #include "defs.h"
 
 #include <sys/cdefs.h>
-__RCSID("$NetBSD: error.c,v 1.7 2011/09/10 21:29:04 christos Exp $");
+__RCSID("$NetBSD: error.c,v 1.8 2013/04/06 14:52:24 christos Exp $");
+/* Id: error.c,v 1.9 2011/09/05 23:27:43 tom Exp  */
 
 /* routines for printing error messages  */
 
diff -r 1a46c728a6a0 -r aed06363581b external/bsd/byacc/dist/lr0.c
--- a/external/bsd/byacc/dist/lr0.c     Sat Apr 06 14:45:24 2013 +0000
+++ b/external/bsd/byacc/dist/lr0.c     Sat Apr 06 14:52:24 2013 +0000
@@ -1,10 +1,10 @@
-/*     $NetBSD: lr0.c,v 1.6 2011/09/10 21:29:04 christos Exp $ */
-/* Id: lr0.c,v 1.12 2010/06/09 08:53:17 tom Exp */
+/*     $NetBSD: lr0.c,v 1.7 2013/04/06 14:52:24 christos Exp $ */
+/* Id: lr0.c,v 1.13 2012/05/26 00:40:47 tom Exp  */
 
 #include "defs.h"
 
 #include <sys/cdefs.h>
-__RCSID("$NetBSD: lr0.c,v 1.6 2011/09/10 21:29:04 christos Exp $");
+__RCSID("$NetBSD: lr0.c,v 1.7 2013/04/06 14:52:24 christos Exp $");
 
 static core *new_state(int symbol);
 static Value_t get_state(int symbol);
@@ -542,7 +542,7 @@
     int empty;
     int done_flag;
 
-    nullable = MALLOC(nsyms);
+    nullable = TMALLOC(char, nsyms);
     NO_SPACE(nullable);
 
     for (i = 0; i < nsyms; ++i)
diff -r 1a46c728a6a0 -r aed06363581b external/bsd/byacc/dist/main.c
--- a/external/bsd/byacc/dist/main.c    Sat Apr 06 14:45:24 2013 +0000
+++ b/external/bsd/byacc/dist/main.c    Sat Apr 06 14:52:24 2013 +0000
@@ -1,24 +1,20 @@
-/*     $NetBSD: main.c,v 1.7 2011/09/10 21:29:04 christos Exp $        */
-/* Id: main.c,v 1.36 2011/09/06 22:44:45 tom Exp */
+/*     $NetBSD: main.c,v 1.8 2013/04/06 14:52:24 christos Exp $        */
 
 #include "defs.h"
 
 #include <sys/cdefs.h>
-__RCSID("$NetBSD: main.c,v 1.7 2011/09/10 21:29:04 christos Exp $");
+__RCSID("$NetBSD: main.c,v 1.8 2013/04/06 14:52:24 christos Exp $");
+/* Id: main.c,v 1.40 2012/09/29 13:11:00 Adrian.Bunk Exp  */
 
 #include <signal.h>
 #include <unistd.h>            /* for _exit() */
 
 
-#if defined(HAVE_ATEXIT)
-# ifdef HAVE_MKSTEMP
-#  define USE_MKSTEMP 1
-# elif defined(HAVE_FCNTL_H)
-#  define USE_MKSTEMP 1
-#  include <fcntl.h>           /* for open(), O_EXCL, etc. */
-# else
-#  define USE_MKSTEMP 0
-# endif
+#ifdef HAVE_MKSTEMP
+# define USE_MKSTEMP 1
+#elif defined(HAVE_FCNTL_H)
+# define USE_MKSTEMP 1
+# include <fcntl.h>            /* for open(), O_EXCL, etc. */
 #else
 # define USE_MKSTEMP 0
 #endif
@@ -43,6 +39,7 @@
 char lflag;
 static char oflag;
 char rflag;
+char sflag;
 char tflag;
 char vflag;
 
@@ -207,6 +204,7 @@
        ,"  -p symbol_prefix      set symbol prefix (default \"yy\")"
        ,"  -P                    create a reentrant parser, e.g., \"%pure-parser\""
        ,"  -r                    produce separate code and table files (y.code.c)"
+       ,"  -s                    suppress #define's for quoted names in %token lines"
        ,"  -t                    add debugging support"
        ,"  -v                    write description (y.output)"
        ,"  -V                    show version information and exit"
@@ -250,6 +248,10 @@
        rflag = 1;
        break;
 
+    case 's':
+       sflag = 1;
+       break;
+
     case 't':
        tflag = 1;
        break;
@@ -368,7 +370,7 @@
 }
 
 #define CREATE_FILE_NAME(dest, suffix) \
-       dest = MALLOC(len + strlen(suffix) + 1); \
+       dest = TMALLOC(char, len + strlen(suffix) + 1); \
        NO_SPACE(dest); \
        strcpy(dest, file_prefix); \
        strcpy(dest + len, suffix)
@@ -399,7 +401,7 @@
     if (prefix != NULL)
     {
        len = (size_t) (prefix - output_file_name);
-       file_prefix = MALLOC(len + 1);
+       file_prefix = TMALLOC(char, len + 1);
        NO_SPACE(file_prefix);
        strncpy(file_prefix, output_file_name, len)[len] = 0;
     }
diff -r 1a46c728a6a0 -r aed06363581b external/bsd/byacc/dist/mkpar.c
--- a/external/bsd/byacc/dist/mkpar.c   Sat Apr 06 14:45:24 2013 +0000
+++ b/external/bsd/byacc/dist/mkpar.c   Sat Apr 06 14:52:24 2013 +0000
@@ -1,10 +1,11 @@
-/*     $NetBSD: mkpar.c,v 1.6 2011/09/10 21:29:04 christos Exp $       */
-/* Id: mkpar.c,v 1.11 2010/06/09 08:53:17 tom Exp */
+/*     $NetBSD: mkpar.c,v 1.7 2013/04/06 14:52:24 christos Exp $       */
+
+/* Id: mkpar.c,v 1.12 2012/05/26 00:42:18 tom Exp  */
 
 #include "defs.h"
 
 #include <sys/cdefs.h>



Home | Main Index | Thread Index | Old Index