+emil header guards

This commit is contained in:
anon 2024-07-22 19:38:36 +02:00
parent fe6d47d90b
commit 166dc3cf2f
5 changed files with 55 additions and 0 deletions
C_C++/emil_header_guards

@ -0,0 +1,11 @@
#ifndef A_H
#include "b.h"
struct a {
int i;
};
#define A_H
#endif

@ -0,0 +1,10 @@
#ifndef A_H
#define A_H
#include "bc.h"
struct a {
int i;
};
#endif

@ -0,0 +1,11 @@
#ifndef B_H
#include "a.h"
struct b {
int i;
};
#define B_H
#endif

@ -0,0 +1,11 @@
#ifndef B_H
#define B_H
#include "ac.h"
struct b {
int i;
};
#endif

@ -0,0 +1,12 @@
// @BAKE gcc main.c -o $*.out
#if 0
# include "a.h"
# include "b.h"
#else
# include "ac.h"
# include "bc.h"
#endif
signed main() {
return 0;
}