mirror of
https://github.com/aljazceru/lightning.git
synced 2026-02-17 20:14:38 +01:00
tools/check-includes.sh: test that c files include their .h files.
This is best-practice (to ensure prototypes match up), but there were a few places we didn't (at least, directly). Make it a requirement, either of form "foo.h" or <dir/foo.h>. The noise is the change to our print templates. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
#include <ccan/array_size/array_size.h>
|
||||
#include <common/htlc.h>
|
||||
#include <common/htlc_state.h>
|
||||
#include "htlc_state_names_gen.h"
|
||||
|
||||
const char *htlc_state_name(enum htlc_state s)
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
#include <ccan/array_size/array_size.h>
|
||||
#include <ccan/cast/cast.h>
|
||||
#include <common/ecdh.h>
|
||||
#include <common/onion.h>
|
||||
#include <common/sphinx.h>
|
||||
#include <sodium/crypto_aead_chacha20poly1305.h>
|
||||
#include <wire/onion_wire.h>
|
||||
|
||||
2
common/peer_status_wiregen.c
generated
2
common/peer_status_wiregen.c
generated
@@ -80,4 +80,4 @@ bool fromwire_status_peer_error(const tal_t *ctx, const void *p, struct channel_
|
||||
fromwire_u8_array(&cursor, &plen, *error_for_them, len);
|
||||
return cursor != NULL;
|
||||
}
|
||||
// SHA256STAMP:a247441c5a012c0dcaab043780943604354ff5c4f360f83b87fcea94816eab8e
|
||||
// SHA256STAMP:3e1d1ae6327232326b2a08f788c59485e0c4abd37bdb55604f111e087f605520
|
||||
|
||||
2
common/peer_status_wiregen.h
generated
2
common/peer_status_wiregen.h
generated
@@ -34,4 +34,4 @@ bool fromwire_status_peer_error(const tal_t *ctx, const void *p, struct channel_
|
||||
|
||||
|
||||
#endif /* LIGHTNING_COMMON_PEER_STATUS_WIREGEN_H */
|
||||
// SHA256STAMP:a247441c5a012c0dcaab043780943604354ff5c4f360f83b87fcea94816eab8e
|
||||
// SHA256STAMP:3e1d1ae6327232326b2a08f788c59485e0c4abd37bdb55604f111e087f605520
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
#include "common/psbt_internal.h"
|
||||
#include <bitcoin/script.h>
|
||||
#include <ccan/ccan/tal/tal.h>
|
||||
#include <common/psbt_internal.h>
|
||||
#include <common/psbt_open.h>
|
||||
#include <wally_psbt.h>
|
||||
#include <wire/peer_wire.h>
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
#include "common/psbt_open.h"
|
||||
#include "config.h"
|
||||
#include <assert.h>
|
||||
#include <bitcoin/psbt.h>
|
||||
#include <bitcoin/script.h>
|
||||
@@ -6,6 +6,7 @@
|
||||
#include <ccan/asort/asort.h>
|
||||
#include <ccan/ccan/endian/endian.h>
|
||||
#include <ccan/ccan/mem/mem.h>
|
||||
#include <common/psbt_open.h>
|
||||
#include <common/pseudorand.h>
|
||||
#include <common/utils.h>
|
||||
|
||||
|
||||
2
common/status_wiregen.c
generated
2
common/status_wiregen.c
generated
@@ -214,4 +214,4 @@ bool fromwire_status_version(const tal_t *ctx, const void *p, wirestring **versi
|
||||
*version = fromwire_wirestring(ctx, &cursor, &plen);
|
||||
return cursor != NULL;
|
||||
}
|
||||
// SHA256STAMP:9a7b4598fad40c5df016c17464c3c8f7b067a17eb993cc65fea42486e3ffb3f7
|
||||
// SHA256STAMP:83a462b28754c5b0c5a496b7e719f15ef6f6c1560f0eea12f76fa4b114189caa
|
||||
|
||||
2
common/status_wiregen.h
generated
2
common/status_wiregen.h
generated
@@ -58,4 +58,4 @@ bool fromwire_status_version(const tal_t *ctx, const void *p, wirestring **versi
|
||||
|
||||
|
||||
#endif /* LIGHTNING_COMMON_STATUS_WIREGEN_H */
|
||||
// SHA256STAMP:9a7b4598fad40c5df016c17464c3c8f7b067a17eb993cc65fea42486e3ffb3f7
|
||||
// SHA256STAMP:83a462b28754c5b0c5a496b7e719f15ef6f6c1560f0eea12f76fa4b114189caa
|
||||
|
||||
Reference in New Issue
Block a user