[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[bug#59993] [PATCH 2/2] tests: Fix implicit function declaration errors
From: |
Zack Weinberg |
Subject: |
[bug#59993] [PATCH 2/2] tests: Fix implicit function declaration errors |
Date: |
Tue, 13 Dec 2022 15:58:10 -0500 |
User-agent: |
Cyrus-JMAP/3.7.0-alpha0-1115-g8b801eadce-fm-20221102.001-g8b801ead |
On Tue, Dec 13, 2022, at 1:30 AM, Frederic Berat wrote:
> On Mon, Dec 12, 2022 at 9:19 PM Zack Weinberg <zack@owlfolio.org> wrote:
>> > --- a/t/ax/depcomp.sh
>> > +++ b/t/ax/depcomp.sh
>> > @@ -243,6 +243,7 @@ cat > sub/subfoo.h <<'END'
>> > #include <stdio.h>
>> > extern int subfoo (void);
>> > END
>> > +cp sub/subfoo.h sub/subfoo.save
>> >
>> > cat > src/baz.c <<'END'
>> > #include "baz.h"
>> > @@ -399,8 +400,7 @@ do_test ()
>> > && rewrite "$srcdir"/sub/subfoo.h echo 'choke me' \
>> > && not $MAKE \
>> > && delete "$srcdir"/sub/subfoo.h \
>> > - && edit "$srcdir"/sub/subfoo.c -e 1d \
>> > - && edit "$srcdir"/foo.h -e 2d \
>> > + && mv "$srcdir"/sub/subfoo.save "$srcdir"/sub/subfoo.h \
>> > && make_ok \
>> > || r='not ok'
>> > result_ "$r" "$pfx dependency tracking works"
>>
>> These changes don't seem to have anything to do with the patch as
>> described. They should be submitted separately.
>
> Actually, that is related. The edit removes the "#include subfoo.h"
> line from foo.h, because the subfoo.h file got overwritten earlier.
> This subfoo.h is the one that had the function declaration in ("extern
> int subfoo (void);" specifically).
> Either you need the original header back, or you need to get the
> declaration back another way. I felt this way was easier than trying
> to insert a declaration without breaking the test.
OK, I clearly don't understand what this test is doing, so I'm going to
defer to someone else to review it.
zw
[bug#59993] [PATCH 2/2] tests: Fix implicit function declaration errors, Frederic Berat, 2022/12/12
[bug#59993] [PATCH 2/2] tests: Fix implicit function declaration errors, Frederic Berat, 2022/12/15
[bug#59993] [PATCH 2/2] tests: Fix implicit function declaration errors, Zack Weinberg, 2022/12/28
[bug#59993] [PATCH v2 2/3] tests: Fix implicit function declaration errors, Frederic Berat, 2022/12/16
[bug#59993] [PATCH v2 3/3] tests: Fix implicit function declaration in ax/depcomp.sh, Frederic Berat, 2022/12/16
[bug#59991] [PATCH 0/2] Port tests to modern C, Karl Berry, 2022/12/12
[bug#59991] [PATCH v2 0/3] Port tests to modern C, Frederic Berat, 2022/12/16