Hi Francis,

On Tue, 2010-07-20 at 22:06 -0400, Francis Giraldeau wrote:
> For those that may want to try the XML lens, here it is. The latest
> square2 branch is needed. Lot of work to be done, but still it shows
> what it's possible to do. 

I just had a look at your branch, and it looks very good. There's some
minor nits that I noticed on a quick look over the code:

      * for development, you should run autogen.sh with
        --enable-compile-warnings=error - this will make sure that gcc
        barfs on as many things as possible. Attached is the trivial
        patch to fix failures from a couple bad printf's
      * stylistically, try to match the style of the existing code as
        much as possible (e.g., in 'if (cond) {' there's always a space
        before the '{')
      * Can we rename state->tip to something more obvious, like
        state->square ?

We should figure out how to best get your changes into the tree, so I
can review them fully. I suggest that your square2 branch should become
3 patch series, which you can send in independently of each other. The
first one should be about adding the square lens, the second adding the
XML lens, and the third the httpd lens.

You should restructure your patches in such a way that each of these
patch series can stand on their own; the XML and httpd lens can each be
a single patch. For the square lens, a single patch might be enough, too
(unless you can think of an obvious way to split that up so that it's
easier to review; one strict requirement is that 'make check' must pass
after each individual patch has been applied) I hope you're familiar
with 'git rebase -i' - if not, you'll really like it by the time this is
all done.

cheers,
David
>From 354c2e7824c9f7df4a6ce211ad7dece15686bc26 Mon Sep 17 00:00:00 2001
From: David Lutterkort <[email protected]>
Date: Fri, 23 Jul 2010 17:04:43 -0700
Subject: [PATCH] fix compile error

---
 src/get.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/get.c b/src/get.c
index eefbfb2..ca198ec 100644
--- a/src/get.c
+++ b/src/get.c
@@ -563,12 +563,12 @@ static struct skel *parse_concat(struct lens *lens, struct state *state,
 
 void dump_regs(struct state *state);
 void dump_regs(struct state *state){
-	printf("state->nreg=%d\tstate->nregs->num_regs=%d\n", state->nreg, state->regs->num_regs);
+	printf("state->nreg=%d\tstate->nregs->num_regs=%zd\n", state->nreg, state->regs->num_regs);
 	for (int i=0; i<state->regs->num_regs;i++){
 		const char *start = state->text + state->regs->start[i];
 		uint size = state->regs->end[i] - state->regs->start[i];
 		char *s = strndup(start, size);
-		printf("%d state->nregs->start=%d\tstate->nregs->end=%d %s\n", i, state->regs->start[i], state->regs->end[i], s);
+		printf("%d state->nregs->start=%zd\tstate->nregs->end=%zd %s\n", i, state->regs->start[i], state->regs->end[i], s);
 		free(s);
 	}
 }
-- 
1.7.1.1

_______________________________________________
augeas-devel mailing list
[email protected]
https://www.redhat.com/mailman/listinfo/augeas-devel

Reply via email to