[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH 2/3] maint: simplify parse-gram.y
From: |
Akim Demaille |
Subject: |
Re: [PATCH 2/3] maint: simplify parse-gram.y |
Date: |
Sun, 6 May 2012 10:45:03 +0200 |
Le 6 mai 2012 à 09:31, Jim Meyering a écrit :
> Pushed.
FTR, I have installed this. Your regen step did not
use xmemdup0 for some reason, so the generated code
works, but breaks on the next regeneration.
From e54ec80c0c163e7a9e24fc2eee6c42a61cbe4316 Mon Sep 17 00:00:00 2001
From: Akim Demaille <address@hidden>
Date: Sun, 6 May 2012 10:20:43 +0200
Subject: [PATCH 4/6] maint: import the xmemdup0 gnulib module.
* bootstrap.conf: Require this module.
* src/parse-gram.y: Include xmemdup0.h.
---
bootstrap.conf | 3 ++-
lib/.gitignore | 2 ++
src/parse-gram.y | 1 +
3 files changed, 5 insertions(+), 1 deletion(-)
diff --git a/bootstrap.conf b/bootstrap.conf
index e1fd548..3303ef3 100644
--- a/bootstrap.conf
+++ b/bootstrap.conf
@@ -26,7 +26,8 @@ gnulib_modules='
quote quotearg realloc-posix
spawn-pipe stdbool stpcpy strdup-posix strerror strtoul strverscmp
unistd unistd-safer unlocked-io update-copyright unsetenv verify
- warnings xalloc xalloc-die xstrndup
+ warnings
+ xalloc xalloc-die xmemdup0 xstrndup
fprintf-posix printf-posix snprintf-posix sprintf-posix
vsnprintf-posix vsprintf-posix
diff --git a/lib/.gitignore b/lib/.gitignore
index 43f2628..915a29b 100644
--- a/lib/.gitignore
+++ b/lib/.gitignore
@@ -265,3 +265,5 @@
/xsize.h
/xstrndup.c
/xstrndup.h
+/xmemdup0.c
+/xmemdup0.h
diff --git a/src/parse-gram.y b/src/parse-gram.y
index 8d74549..eb034b0 100644
--- a/src/parse-gram.y
+++ b/src/parse-gram.y
@@ -32,6 +32,7 @@
#include "symlist.h"
#include "scan-gram.h"
#include "scan-code.h"
+#include "xmemdup0.h"
#define YYLLOC_DEFAULT(Current, Rhs, N) (Current) = lloc_default (Rhs, N)
static YYLTYPE lloc_default (YYLTYPE const *, int);
--
1.7.10.1
- nuke strncpy, Jim Meyering, 2012/05/03
- [PATCH 1/3] maint: s/strncpy/memcpy/, when equivalent, Jim Meyering, 2012/05/03
- [PATCH 3/3] maint: regen src/parse-gram.[ch], Jim Meyering, 2012/05/03
- [PATCH 2/3] maint: simplify parse-gram.y, Jim Meyering, 2012/05/03
- Re: [PATCH 2/3] maint: simplify parse-gram.y, Akim Demaille, 2012/05/04
- Re: [PATCH 2/3] maint: simplify parse-gram.y, Jim Meyering, 2012/05/04
- Re: [PATCH 2/3] maint: simplify parse-gram.y, Jim Meyering, 2012/05/05
- Re: [PATCH 2/3] maint: simplify parse-gram.y, Akim Demaille, 2012/05/06
- Re: [PATCH 2/3] maint: simplify parse-gram.y, Jim Meyering, 2012/05/06
- Re: [PATCH 2/3] maint: simplify parse-gram.y,
Akim Demaille <=
- Re: [PATCH 2/3] maint: simplify parse-gram.y, Jim Meyering, 2012/05/06
- Re: [PATCH 2/3] maint: simplify parse-gram.y, Akim Demaille, 2012/05/09