Skip to content

Commit b759443

Browse files
committed
Forward declare strdup from <string.h> to avoid warning during compilation
1 parent 1a7d3e4 commit b759443

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/grammar/parser-lalr-main.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,13 @@
1212
#include <stdarg.h>
1313
#include <stdlib.h>
1414
#include <string.h>
15+
// Forward declare strdup from <string.h> to avoid warning during compilation
16+
char *strdup(const char *s);
1517

1618
extern int yylex();
1719
extern int rsparse();
1820

21+
1922
#define PUSHBACK_LEN 4
2023

2124
static char pushback[PUSHBACK_LEN];

0 commit comments

Comments
 (0)