aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorthegeorg <thegeorg@yandex-team.com>2024-06-09 20:42:41 +0300
committerthegeorg <thegeorg@yandex-team.com>2024-06-09 20:49:53 +0300
commit3ed7a11cff73be232a1e718a1e925ef09e1ca098 (patch)
tree153a2d368e70fc663285ffa25e05ffbd69e3ec4d
parentc191ecd15978bda625d24c6cd94e63618fa0174f (diff)
downloadydb-3ed7a11cff73be232a1e718a1e925ef09e1ca098.tar.gz
contrib/tools/bison: Revert more harmless patches
020fb104b9a689c3747315b1299fdb50e00feb14
-rw-r--r--contrib/tools/bison/lib/binary-io.h3
-rw-r--r--contrib/tools/bison/lib/sig-handler.h3
-rw-r--r--contrib/tools/bison/lib/stdio-impl.h11
-rw-r--r--contrib/tools/bison/lib/string--.h10
-rw-r--r--contrib/tools/bison/lib/xalloc.h3
-rw-r--r--contrib/tools/bison/lib/xsize.h3
-rw-r--r--contrib/tools/bison/src/flex-scanner.h2
-rw-r--r--contrib/tools/bison/src/ielr.c2
-rw-r--r--contrib/tools/bison/src/muscle-tab.h1
-rw-r--r--contrib/tools/bison/src/parse-gram.c1
10 files changed, 6 insertions, 33 deletions
diff --git a/contrib/tools/bison/lib/binary-io.h b/contrib/tools/bison/lib/binary-io.h
index 256c23a0ea..7b4a4c0a1b 100644
--- a/contrib/tools/bison/lib/binary-io.h
+++ b/contrib/tools/bison/lib/binary-io.h
@@ -33,9 +33,6 @@
#define O_TEXT 0
#endif
-#ifndef _GL_INLINE_HEADER_BEGIN
- #error "Please include config.h first."
-#endif
_GL_INLINE_HEADER_BEGIN
#ifndef BINARY_IO_INLINE
# define BINARY_IO_INLINE _GL_INLINE
diff --git a/contrib/tools/bison/lib/sig-handler.h b/contrib/tools/bison/lib/sig-handler.h
index 67d061d599..ca9f979c41 100644
--- a/contrib/tools/bison/lib/sig-handler.h
+++ b/contrib/tools/bison/lib/sig-handler.h
@@ -20,9 +20,6 @@
#include <signal.h>
-#ifndef _GL_INLINE_HEADER_BEGIN
- #error "Please include config.h first."
-#endif
_GL_INLINE_HEADER_BEGIN
#ifndef SIG_HANDLER_INLINE
# define SIG_HANDLER_INLINE _GL_INLINE
diff --git a/contrib/tools/bison/lib/stdio-impl.h b/contrib/tools/bison/lib/stdio-impl.h
index e510bb8f42..18575555a0 100644
--- a/contrib/tools/bison/lib/stdio-impl.h
+++ b/contrib/tools/bison/lib/stdio-impl.h
@@ -14,6 +14,10 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
+/* Many stdio implementations have the same logic and therefore can share
+ the same implementation of stdio extension API, except that some fields
+ have different naming conventions, or their access requires some casts. */
+
/* Glibc 2.28 made _IO_IN_BACKUP private. For now, work around this
problem by defining it ourselves. FIXME: Do not rely on glibc
internals. */
@@ -21,11 +25,6 @@
# define _IO_IN_BACKUP 0x100
#endif
-/* Many stdio implementations have the same logic and therefore can share
- the same implementation of stdio extension API, except that some fields
- have different naming conventions, or their access requires some casts. */
-
-
/* BSD stdio derived implementations. */
#if defined __NetBSD__ /* NetBSD */
@@ -64,7 +63,7 @@
# define fp_ fp
# endif
-# if (defined __NetBSD__ && __NetBSD_Version__ >= 105270000) || defined __OpenBSD__ || defined __ANDROID__ /* NetBSD >= 1.5ZA, OpenBSD, Android */
+# if (defined __NetBSD__ && __NetBSD_Version__ >= 105270000) || defined __OpenBSD__ /* NetBSD >= 1.5ZA, OpenBSD */
/* See <http://cvsweb.netbsd.org/bsdweb.cgi/src/lib/libc/stdio/fileext.h?rev=HEAD&content-type=text/x-cvsweb-markup>
and <http://www.openbsd.org/cgi-bin/cvsweb/src/lib/libc/stdio/fileext.h?rev=HEAD&content-type=text/x-cvsweb-markup> */
struct __sfileext
diff --git a/contrib/tools/bison/lib/string--.h b/contrib/tools/bison/lib/string--.h
deleted file mode 100644
index 24a1932992..0000000000
--- a/contrib/tools/bison/lib/string--.h
+++ /dev/null
@@ -1,10 +0,0 @@
-#pragma once
-
-#include <string.h>
-
-#if defined(_WIN32)
-void *rawmemchr(const void *s, int c);
-char *stpcpy(char *dest, const char *src);
-#endif
-
-int strverscmp(const char *s1, const char *s2);
diff --git a/contrib/tools/bison/lib/xalloc.h b/contrib/tools/bison/lib/xalloc.h
index 6c9b53bf6f..da7c4b6bb3 100644
--- a/contrib/tools/bison/lib/xalloc.h
+++ b/contrib/tools/bison/lib/xalloc.h
@@ -22,9 +22,6 @@
#include "xalloc-oversized.h"
-#ifndef _GL_INLINE_HEADER_BEGIN
- #error "Please include config.h first."
-#endif
_GL_INLINE_HEADER_BEGIN
#ifndef XALLOC_INLINE
# define XALLOC_INLINE _GL_INLINE
diff --git a/contrib/tools/bison/lib/xsize.h b/contrib/tools/bison/lib/xsize.h
index 5675593f54..2922f35305 100644
--- a/contrib/tools/bison/lib/xsize.h
+++ b/contrib/tools/bison/lib/xsize.h
@@ -27,9 +27,6 @@
# include <stdint.h>
#endif
-#ifndef _GL_INLINE_HEADER_BEGIN
- #error "Please include config.h first."
-#endif
_GL_INLINE_HEADER_BEGIN
#ifndef XSIZE_INLINE
# define XSIZE_INLINE _GL_INLINE
diff --git a/contrib/tools/bison/src/flex-scanner.h b/contrib/tools/bison/src/flex-scanner.h
index 03c9ec64fd..d72986e812 100644
--- a/contrib/tools/bison/src/flex-scanner.h
+++ b/contrib/tools/bison/src/flex-scanner.h
@@ -21,8 +21,6 @@
# error "FLEX_PREFIX not defined"
#endif
-#include <obstack.h>
-
/* Flex full version as a number. */
#define FLEX_VERSION \
((YY_FLEX_MAJOR_VERSION) * 1000000 \
diff --git a/contrib/tools/bison/src/ielr.c b/contrib/tools/bison/src/ielr.c
index 38156b384d..5500523170 100644
--- a/contrib/tools/bison/src/ielr.c
+++ b/contrib/tools/bison/src/ielr.c
@@ -1032,9 +1032,9 @@ ielr_split_states (bitsetv follow_kernel_items, bitsetv always_follows,
lookahead sets. */
if (!annotation_lists)
{
- state_list *node;
timevar_push (TV_IELR_PHASE4);
initialize_LA ();
+ state_list *node;
for (node = first_state; node; node = node->next)
if (!node->state->consistent)
{
diff --git a/contrib/tools/bison/src/muscle-tab.h b/contrib/tools/bison/src/muscle-tab.h
index 2150327ba6..0993f74ed7 100644
--- a/contrib/tools/bison/src/muscle-tab.h
+++ b/contrib/tools/bison/src/muscle-tab.h
@@ -21,7 +21,6 @@
# define MUSCLE_TAB_H_
# include <quotearg.h>
-# include <obstack.h>
# include "location.h"
diff --git a/contrib/tools/bison/src/parse-gram.c b/contrib/tools/bison/src/parse-gram.c
index 5b862667e9..b48ed6ffc6 100644
--- a/contrib/tools/bison/src/parse-gram.c
+++ b/contrib/tools/bison/src/parse-gram.c
@@ -63,7 +63,6 @@
/* On column 0 to please syntax-check. */
#include <config.h>
-#include "string--.h"
#line 68 "src/parse-gram.c" /* yacc.c:316 */
/* Substitute the type names. */